[PATCH] smbd: Use mutex instead of fcntl lock for echohandler coordination
Stefan (metze) Metzmacher
metze at samba.org
Mon Jul 7 16:57:05 MDT 2014
Hi Christof,
> +static bool smbd_echo_active(struct smbd_server_connection *sconn)
> +{
> + return (sconn->smb1.echo_handler.socket_lock_fd != -1
> +#ifdef HAVE_ROBUST_MUTEXES
> + || sconn->smb1.echo_handler.socket_mutex != NULL
> +#endif
> + );
> +}
Can you please use if statements like this:
if (sconn->smb1.echo_handler.socket_lock_fd != -1) {
return true;
}
#ifdef HAVE_ROBUST_MUTEXES
if (sconn->smb1.echo_handler.socket_mutex != NULL) {
return true;
}
#endif
return false;
The rest look good thanks!
metze
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 246 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20140708/b99a1df5/attachment.pgp>
More information about the samba-technical
mailing list