]> git.ipfire.org Git - thirdparty/bacula.git/commit
win32: tweak fix warning
authorAlain Spineux <alain@baculasystems.com>
Wed, 7 Jun 2023 09:48:40 +0000 (11:48 +0200)
committerEric Bollengier <eric@baculasystems.com>
Thu, 14 Sep 2023 11:57:01 +0000 (13:57 +0200)
commita4eb91637daea7d3e47f6f8bfa03d166929fb5b2
treee797d500f02aef0e78fa182bff0fceda1de8f663
parent6d1a588a968d4f70d0233e7ef2a07144be0fe3b3
win32: tweak fix warning

- sendit() already handle the final '\O' no need to include it in the len
- fir warning:
In file included from /home/bac/workspace/bee/bacula/src/stored/status.c:30:
In function ‘void sendit(const char*, int, STATUS_PKT*)’,
    inlined from ‘void list_one_device(char*, DEVICE*, STATUS_PKT*, OutputWriter*)’ at /home/bac/workspace/bee/bacula/src/stored/status.c:407:24,
    inlined from ‘void list_devices(STATUS_PKT*, char*)’ at /home/bac/workspace/bee/bacula/src/stored/status.c:498:25:
/home/bac/workspace/bee/bacula/src/lib/status.h:46:13: warning: ‘void* memcpy(void*, const void*, size_t)’ forming offset 4 is out of the bounds [0, 4] [-Warray-bounds]
   46 |       memcpy(user->msg, msg, len+1);
      |       ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
bacula/src/stored/status.c