s3:smbget: Fix buffer truncation issues with gcc8
commit84bac589f3d4f8ce7131d374963f275ea80af80b
authorAndreas Schneider <asn@samba.org>
Mon, 18 Jun 2018 08:43:53 +0000 (18 10:43 +0200)
committerKarolin Seeger <kseeger@samba.org>
Wed, 27 Jun 2018 08:34:22 +0000 (27 10:34 +0200)
treeabcbd985fdf26e6a620438efe83757bdd4277fc0
parente0a7415b48cf986ae8359e88dfd1eee51b7a2cb8
s3:smbget: Fix buffer truncation issues with gcc8

../source3/utils/smbget.c: In function ‘smb_download_file’:
../source3/utils/smbget.c:97:27: error: ‘b’ directive output may be truncated writing 1 byte into a region of size between 0 and 19 [-Werror=format-truncation=]
   snprintf(buffer, l, "%jdb", (intmax_t)s);
                           ^

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13437

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
(cherry picked from commit 4a3164e0beea35c1f4ce44fbe43547f7104587d1)
source3/utils/smbget.c