Fix a few printf format errors
authorVolker Lendecke <vl@samba.org>
Wed, 6 May 2015 14:25:51 +0000 (16:25 +0200)
committerJeremy Allison <jra@samba.org>
Thu, 7 May 2015 18:20:19 +0000 (20:20 +0200)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
lib/util/util_runcmd.c
source3/modules/vfs_aio_fork.c
source3/modules/vfs_fruit.c
source3/rpc_server/fssd.c
source4/smbd/process_standard.c

index 46c455d3d0349084ca332d94ba9de6e54b1f79e4..f18e37bcb2d46839c41cf590a03113504e9a6e88 100644 (file)
@@ -291,7 +291,7 @@ static void samba_runcmd_io_handler(struct tevent_context *ev,
                                        DEBUG(0, ("Error in waitpid() unexpectedly got ECHILD "
                                                  "for %s child %d - %s, "
                                                  "someone has set SIGCHLD to SIG_IGN!\n",
-                                         state->arg0, state->pid, strerror(errno)));
+                                       state->arg0, (int)state->pid, strerror(errno)));
                                        tevent_req_error(req, errno);
                                        return;
                                }
index dea81070c9aef6b392b2577def143313f487eb35..b15cf9dcfc854df6c3603e4a5b97e7127ec3d7e7 100644 (file)
@@ -398,7 +398,7 @@ static int aio_child_destructor(struct aio_child *child)
        SMB_ASSERT(!child->busy);
 
        DEBUG(10, ("aio_child_destructor: removing child %d on fd %d\n",
-                       child->pid, child->sockfd));
+                  (int)child->pid, child->sockfd));
 
        /*
         * closing the sockfd makes the child not return from recvmsg() on RHEL
@@ -471,7 +471,7 @@ static int create_aio_child(struct smbd_server_connection *sconn,
        }
 
        DEBUG(10, ("Child %d created with sockfd %d\n",
-                       result->pid, fdpair[0]));
+                  (int)result->pid, fdpair[0]));
 
        result->sockfd = fdpair[0];
        close(fdpair[1]);
index dffb260acb78984cc4a7e9817182a0d7d77f92aa..8a5588dd67d9ac643aec780b8ebb624561eb77ea 100644 (file)
@@ -1982,7 +1982,7 @@ static NTSTATUS check_ms_nfs(vfs_handle_struct *handle,
                        *pdo_chmod = true;
 
                        DEBUG(10, ("MS NFS chmod request %s, %04o\n",
-                                  fsp_str_dbg(fsp), *pmode));
+                                  fsp_str_dbg(fsp), (unsigned)(*pmode)));
                        break;
                }
        }
@@ -3439,7 +3439,8 @@ static NTSTATUS fruit_fset_nt_acl(vfs_handle_struct *handle,
 
                if (result != 0) {
                        DEBUG(1, ("chmod: %s, result: %d, %04o error %s\n", fsp_str_dbg(fsp),
-                                 result, ms_nfs_mode, strerror(errno)));
+                                 result, (unsigned)ms_nfs_mode,
+                                 strerror(errno)));
                        status = map_nt_error_from_unix(errno);
                        return status;
                }
index fc1f630c6bb29dbfe38d370b118ed94aa71ff480..0f8b02e98473ee8380c124b7a71c69e2f1fba488 100644 (file)
@@ -209,7 +209,8 @@ void start_fssd(struct tevent_context *ev_ctx,
                exit(1);
        }
 
-       DEBUG(1, ("File Server Shadow-copy Daemon Started (%d)\n", getpid()));
+       DEBUG(1, ("File Server Shadow-copy Daemon Started (%d)\n",
+                 (int)getpid()));
 
        /* loop forever */
        rc = tevent_loop_wait(ev_ctx);
index e2b9f13046d688de2393659cd87ef2df86ae734e..b55a1a7f309fc875ea16a68b29690ed276478357 100644 (file)
@@ -104,12 +104,13 @@ static void standard_child_pipe_handler(struct tevent_context *ev,
                        DEBUG(0, ("Error in waitpid() unexpectedly got ECHILD "
                                  "for child %d (%s) - %s, someone has set SIGCHLD "
                                  "to SIG_IGN!\n",
-                                 state->pid, state->name, strerror(errno)));
+                                 (int)state->pid, state->name,
+                                 strerror(errno)));
                        TALLOC_FREE(state);
                        return;
                }
                DEBUG(0, ("Error in waitpid() for child %d (%s) - %s \n",
-                         state->pid, state->name, strerror(errno)));
+                         (int)state->pid, state->name, strerror(errno)));
                if (errno == 0) {
                        errno = ECHILD;
                }
@@ -119,11 +120,11 @@ static void standard_child_pipe_handler(struct tevent_context *ev,
        if (WIFEXITED(status)) {
                status = WEXITSTATUS(status);
                DEBUG(2, ("Child %d (%s) exited with status %d\n",
-                         state->pid, state->name, status));
+                         (int)state->pid, state->name, status));
        } else if (WIFSIGNALED(status)) {
                status = WTERMSIG(status);
                DEBUG(0, ("Child %d (%s) terminated with signal %d\n",
-                         state->pid, state->name, status));
+                         (int)state->pid, state->name, status));
        }
        TALLOC_FREE(state);
        return;