From 2403d1e1661904a981a750b0c001986f86e3b762 Mon Sep 17 00:00:00 2001 From: Jan Polensky Date: Thu, 2 Oct 2025 15:06:12 +0200 Subject: [PATCH] zdsfs: Replace bzero with memset MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace deprecated bzero() with memset() to maintain portability and comply with the C standard. No functional change. Link: https://www.man7.org/linux/man-pages/man3/bzero.3.html Reviewed-by: Jan Höppner Signed-off-by: Jan Polensky Signed-off-by: Jan Höppner --- zdsfs/zdsfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zdsfs/zdsfs.c b/zdsfs/zdsfs.c index 778c9f3c..84340114 100644 --- a/zdsfs/zdsfs.c +++ b/zdsfs/zdsfs.c @@ -1328,7 +1328,7 @@ static void zdsfs_process_device_file(const char *devfile) if (sb.st_size) { size = (size_t)sb.st_size + 1; buffer = malloc(size); - bzero(buffer, size); + memset(buffer, 0, size); if (!buffer) { fprintf(stderr, "could not allocate memory to buffer" " file %s\n", devfile); @@ -1698,7 +1698,7 @@ int main(int argc, char *argv[]) int rc; timer_running = 0; - bzero(&zdsfsinfo, sizeof(zdsfsinfo)); + memset(&zdsfsinfo, 0, sizeof(zdsfsinfo)); zdsfsinfo.keepRDW = 0; zdsfsinfo.allow_inclomplete_multi_volume = 0; zdsfsinfo.tracks_per_frame = 128;