1
0
mirror of https://github.com/samba-team/samba.git synced 2025-07-30 19:42:05 +03:00

scannedonly: Fix CID 242109 Unchecked return value from library

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
Volker Lendecke
2013-12-15 21:07:00 +01:00
committed by Jeremy Allison
parent 65d0dceea5
commit 5677c63f1c

View File

@ -228,10 +228,12 @@ static int connect_to_scanner(vfs_handle_struct * handle)
large directory with lots of unscanned files. */
int sndsize;
socklen_t size = sizeof(int);
getsockopt(so->socket, SOL_SOCKET, SO_RCVBUF,
(char *)&sndsize, &size);
DEBUG(SCANNEDONLY_DEBUG, ("current socket buffer size=%d\n",
sndsize));
if (getsockopt(so->socket, SOL_SOCKET, SO_RCVBUF,
(char *)&sndsize, &size) == 0) {
DEBUG(SCANNEDONLY_DEBUG,
("current socket buffer size=%d\n",
sndsize));
}
sndsize = 262144;
if (setsockopt(so->socket, SOL_SOCKET, SO_RCVBUF,
(char *)&sndsize,