compiler found an error in handle_aio_read_complete

Andrew Bartlett abartlet at samba.org
Sun Jul 22 21:00:55 MDT 2012


Watching a build recently, I noticed:

../source3/smbd/reply.c: In function ‘do_smb1_close’:
../source3/smbd/reply.c:4948:6: warning: pointer targets in passing argument 2 of ‘srv_send_smb’ differ in signedness [-Wpointer-sign]
../source3/smbd/proto.h:744:7: note: expected ‘char *’ but argument is of type ‘uint8_t *’
../source3/smbd/reply.c:4948:6: warning: the address of ‘encrypt’ will always evaluate as ‘true’ [-Waddress]

This looks like your recent code:

3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4946)   }
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4947)   if (!srv_send_smb(smbreq->sconn, smbreq->outbuf, true,
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4948)                     smbreq->seqnum+1, encrypt, NULL)) {
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4949)           exit_server_cleanly("handle_aio_read_complete: srv_send_smb "
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4950)                               "failed.");
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4951)   }
3e9f58be (Volker Lendecke             2012-07-17 22:24:51 +0200 4952)   TALLOC_FREE(smbreq);

That is, there is no local variable encrypt, so it must be finding some
function or pointer by that name somewhere. 

Andrew Bartlett

-- 
Andrew Bartlett                                http://samba.org/~abartlet/
Authentication Developer, Samba Team           http://samba.org



More information about the samba-technical mailing list