s3:smbd: Fix bug 6690, wrong error check
authorAndrew Klosterman <andrew.klosterman+samba_bugzilla@gmail.com>
Tue, 8 Sep 2009 15:38:37 +0000 (17:38 +0200)
committerVolker Lendecke <vl@samba.org>
Tue, 8 Sep 2009 15:39:51 +0000 (17:39 +0200)
source3/profile/profile.c

index 6d2d5ae06d8ebda6b9b38aecc47767904e66b08e..61b0a7cc68572932b24d48d29a39d49e332d486a 100644 (file)
@@ -227,7 +227,7 @@ bool profile_setup(struct messaging_context *msg_ctx, bool rdonly)
        
        profile_h = (struct profile_header *)shmat(shm_id, 0, 
                                                   read_only?SHM_RDONLY:0);
-       if ((long)profile_p == -1) {
+       if ((long)profile_h == -1) {
                DEBUG(0,("Can't attach to IPC area. Error was %s\n", 
                         strerror(errno)));
                return False;