From 0e091a52074655aedeeaad488d61e241909a3dc5 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 23 Sep 1998 17:56:34 +0000 Subject: [PATCH] Hoist by my own petard with warnings (forgot to set strict warnings in Makefile before compiling & checking in :-). Jeremy. (This used to be commit 05fb3c82a57549fba74016eae31b53de30417b3c) --- source3/smbd/oplock.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c index b87d664046b..d73fcda117d 100644 --- a/source3/smbd/oplock.c +++ b/source3/smbd/oplock.c @@ -166,7 +166,7 @@ Error was %s.\n", strerror(errno) )); inode = (SMB_DEV_T)os.os_ino; DEBUG(5,("receive_local_message: kernel oplock break request received for \ -dev = %x, inode = %0.f\n", (unsigned int)dev, (double)inode )); +dev = %x, inode = %.0f\n", (unsigned int)dev, (double)inode )); /* * Create a kernel oplock break message. @@ -243,12 +243,12 @@ BOOL set_file_oplock(files_struct *fsp) if(fcntl(fsp->fd_ptr->fd, F_OPLKREG, oplock_pipe_write) < 0) { if(errno != EAGAIN) { DEBUG(0,("set_file_oplock: Unable to get kernel oplock on file %s, dev = %x, \ -inode = %0.f. Error was %s\n", +inode = %.0f. Error was %s\n", fsp->fsp_name, (unsigned int)fsp->fd_ptr->dev, (double)fsp->fd_ptr->inode, strerror(errno) )); } else { DEBUG(5,("set_file_oplock: Refused oplock on file %s, dev = %x, \ -inode = %0.f. Another process had the file open.\n", +inode = %.0f. Another process had the file open.\n", fsp->fsp_name, (unsigned int)fsp->fd_ptr->dev, (double)fsp->fd_ptr->inode )); } return False; @@ -1026,7 +1026,7 @@ void check_kernel_oplocks(void) int pfd[2]; pstring tmpname; - slprintf( tmpname, sizeof(tmpname)-1, "/tmp/ot.%d.XXXXXX", getpid()); + slprintf( tmpname, sizeof(tmpname)-1, "/tmp/ot.%d.XXXXXX", (unsigned int)getpid()); mktemp(tmpname); if(pipe(pfd) != 0) { @@ -1048,7 +1048,7 @@ void check_kernel_oplocks(void) if(fcntl(fd, F_OPLKREG, pfd[1]) == -1) { DEBUG(0,("check_kernel_oplocks: Kernel oplocks are not available on this machine. \ -Disabling kernel oplock supprt.\n" )); +Disabling kernel oplock support.\n" )); close(pfd[0]); close(pfd[1]); close(fd); @@ -1057,7 +1057,7 @@ Disabling kernel oplock supprt.\n" )); if(fcntl(fd, F_OPLKACK, OP_REVOKE) < 0 ) { DEBUG(0,("check_kernel_oplocks: Error when removing kernel oplock. Error was %s. \ -Disabling kernel oplock supprt.\n" )); +Disabling kernel oplock support.\n", strerror(errno) )); close(pfd[0]); close(pfd[1]); close(fd);