Re: pg_verifybackup: TAR format backup verification
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Amul Sul <sulamul@gmail.com>, Sravan Kumar <sravanvcybage@gmail.com>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2024-09-30T20:11:58Z
Lists: pgsql-hackers
On Mon, Sep 30, 2024 at 11:31 AM Tom Lane <tgl@sss.pgh.pa.us> wrote: > WFM, modulo the suggestion about changing data types. I would prefer not to make the data type change here because it has quite a few tentacles. If I change member_copy_control_data() then I have to change astreamer_verify_content() which means changing the astreamer interface which means adjusting all of the other astreamers. That can certainly be done, but it's quite possible it might provoke some other Coverity warning. Since this is a length, it might've been better to use an unsigned data type, but there's no reason that I can see why it should be size_t specifically: the origin of the value could be either the return value of read(), which is ssize_t not size_t, or the number of bytes returned by a decompression library or the number of bytes present in a protocol message. Trying to make things fit better here is just likely to make them fit worse someplace else. "You are in a maze of twisty little data types, all alike." -- Robert Haas EDB: http://www.enterprisedb.com
Commits
-
Adjust json_manifest_per_file_callback API in one more place.
- 554d3a18f362 18.0 landed
-
File size in a backup manifest should use uint64, not size_t.
- d94cf5ca7fad 18.0 landed
-
Fix some pg_verifybackup issues reported by Coverity.
- fc1b2ce0ee9c 18.0 landed
-
pg_verifybackup: Move some declarations to new pg_verifybackup.h
- aa2d6b15d6d6 18.0 landed
-
pg_verifybackup: Move skip_checksums into verifier_context.
- af99d44a889f 18.0 landed
-
Improve file header comments for astramer code.
- 22b4a1b561f8 18.0 landed
-
Move astreamer (except astreamer_inject) to fe_utils.
- f80b09bac87d 18.0 landed
-
Move recovery injector astreamer to a separate header file.
- 53b2c921a0f9 18.0 landed
-
Rename bbstreamer to astreamer.
- 3c905698114d 18.0 landed