examples/testsmbc.c - substitute deprecated function "bzero" with "memset"
authorMatthias Dieter Wallnöfer <mdw@samba.org>
Mon, 20 Feb 2012 08:27:13 +0000 (09:27 +0100)
committerAndrew Tridgell <tridge@samba.org>
Wed, 22 Feb 2012 22:57:24 +0000 (23:57 +0100)
Here we do not make any use of libreplace and hence it would be overkill
to include the right headers for Solaris.

This fixes bug: https://bugzilla.samba.org/show_bug.cgi?id=8767

Signed-off-by: Andrew Tridgell <tridge@samba.org>
examples/libsmbclient/testsmbc.c

index 47fb130edd40195da10fbeef8667aed55fbab26a..1f98c3afa7a0a454494b6bef04cb43d52b49d156 100644 (file)
@@ -114,7 +114,7 @@ int main(int argc, char *argv[])
 
   /* Now, write some date to the file ... */
 
 
   /* Now, write some date to the file ... */
 
-  bzero(buff, sizeof(buff));
+  memset(buff, '\0', sizeof(buff));
   strcpy(buff, "Some test data for the moment ...");
 
   err = smbc_write(fd, buff, sizeof(buff));
   strcpy(buff, "Some test data for the moment ...");
 
   err = smbc_write(fd, buff, sizeof(buff));