diff options
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/ctdbd_conn.c | 4 | ||||
-rw-r--r-- | source3/lib/pidfile.c | 2 | ||||
-rw-r--r-- | source3/lib/server_prefork.c | 4 | ||||
-rw-r--r-- | source3/lib/smbldap.c | 4 | ||||
-rw-r--r-- | source3/lib/smbrun.c | 4 | ||||
-rw-r--r-- | source3/lib/substitute.c | 2 | ||||
-rw-r--r-- | source3/lib/system.c | 2 | ||||
-rw-r--r-- | source3/lib/tdb_validate.c | 2 | ||||
-rw-r--r-- | source3/lib/util.c | 8 |
9 files changed, 16 insertions, 16 deletions
diff --git a/source3/lib/ctdbd_conn.c b/source3/lib/ctdbd_conn.c index 36e9e508f07..ba511379151 100644 --- a/source3/lib/ctdbd_conn.c +++ b/source3/lib/ctdbd_conn.c @@ -578,7 +578,7 @@ NTSTATUS ctdbd_messaging_connection(TALLOC_CTX *mem_ctx, return status; } - status = register_with_ctdbd(conn, (uint64_t)sys_getpid()); + status = register_with_ctdbd(conn, (uint64_t)getpid()); if (!NT_STATUS_IS_OK(status)) { goto fail; } @@ -665,7 +665,7 @@ static NTSTATUS ctdb_handle_message(uint8_t *buf, size_t length, } /* only messages to our pid or the broadcast are valid here */ - if (msg->srvid != sys_getpid() && msg->srvid != MSG_SRVID_SAMBA) { + if (msg->srvid != getpid() && msg->srvid != MSG_SRVID_SAMBA) { DEBUG(0,("Got unexpected message with srvid=%llu\n", (unsigned long long)msg->srvid)); TALLOC_FREE(buf); diff --git a/source3/lib/pidfile.c b/source3/lib/pidfile.c index 06fca91165d..469ddbd95fd 100644 --- a/source3/lib/pidfile.c +++ b/source3/lib/pidfile.c @@ -162,7 +162,7 @@ void pidfile_create(const char *program_name) } memset(buf, 0, sizeof(buf)); - slprintf(buf, sizeof(buf) - 1, "%u\n", (unsigned int) sys_getpid()); + slprintf(buf, sizeof(buf) - 1, "%u\n", (unsigned int)getpid()); if (write(fd, buf, strlen(buf)) != (ssize_t)strlen(buf)) { DEBUG(0,("ERROR: can't write to file %s: %s\n", pidFile_name, strerror(errno))); diff --git a/source3/lib/server_prefork.c b/source3/lib/server_prefork.c index f9df91417c9..3d35e1c6ca6 100644 --- a/source3/lib/server_prefork.c +++ b/source3/lib/server_prefork.c @@ -106,7 +106,7 @@ bool prefork_create_pool(TALLOC_CTX *mem_ctx, pfp->pool[i].allowed_clients = 1; pfp->pool[i].started = now; - pid = sys_fork(); + pid = fork(); switch (pid) { case -1: DEBUG(1, ("Failed to prefork child n. %d !\n", i)); @@ -194,7 +194,7 @@ int prefork_add_children(struct tevent_context *ev_ctx, pfp->pool[i].allowed_clients = 1; pfp->pool[i].started = now; - pid = sys_fork(); + pid = fork(); switch (pid) { case -1: DEBUG(1, ("Failed to prefork child n. %d !\n", j)); diff --git a/source3/lib/smbldap.c b/source3/lib/smbldap.c index 51bcabd5ebf..c01d3fdc692 100644 --- a/source3/lib/smbldap.c +++ b/source3/lib/smbldap.c @@ -1070,7 +1070,7 @@ static int smbldap_open(struct smbldap_state *ldap_state) ldap_state->last_ping = time_mono(NULL); - ldap_state->pid = sys_getpid(); + ldap_state->pid = getpid(); TALLOC_FREE(ldap_state->idle_event); @@ -1157,7 +1157,7 @@ static void setup_ldap_local_alarm(struct smbldap_state *ldap_state, time_t abso alarm(absolute_endtime - now); } - if (ldap_state->pid != sys_getpid()) { + if (ldap_state->pid != getpid()) { smbldap_close(ldap_state); } } diff --git a/source3/lib/smbrun.c b/source3/lib/smbrun.c index 75713d2aa2f..b38dee1665b 100644 --- a/source3/lib/smbrun.c +++ b/source3/lib/smbrun.c @@ -92,7 +92,7 @@ static int smbrun_internal(const char *cmd, int *outfd, bool sanitize) CatchChildLeaveStatus(); - if ((pid=sys_fork()) < 0) { + if ((pid=fork()) < 0) { DEBUG(0,("smbrun: fork failed with error %s\n", strerror(errno) )); CatchChild(); if (outfd) { @@ -255,7 +255,7 @@ int smbrunsecret(const char *cmd, const char *secret) CatchChildLeaveStatus(); - if ((pid=sys_fork()) < 0) { + if ((pid=fork()) < 0) { DEBUG(0, ("smbrunsecret: fork failed with error %s\n", strerror(errno))); CatchChild(); return errno; diff --git a/source3/lib/substitute.c b/source3/lib/substitute.c index 08cc03eeb27..44582860a19 100644 --- a/source3/lib/substitute.c +++ b/source3/lib/substitute.c @@ -549,7 +549,7 @@ char *talloc_sub_basic(TALLOC_CTX *mem_ctx, get_remote_arch_str()); break; case 'd' : - slprintf(pidstr,sizeof(pidstr)-1, "%d",(int)sys_getpid()); + slprintf(pidstr,sizeof(pidstr)-1, "%d",(int)getpid()); a_string = realloc_string_sub(a_string, "%d", pidstr); break; case 'h' : diff --git a/source3/lib/system.c b/source3/lib/system.c index f6558530f32..92e244fdbe9 100644 --- a/source3/lib/system.c +++ b/source3/lib/system.c @@ -1404,7 +1404,7 @@ int sys_popen(const char *command) if(!(argl = extract_args(NULL, command))) goto err_exit; - entry->child_pid = sys_fork(); + entry->child_pid = fork(); if (entry->child_pid == -1) { goto err_exit; diff --git a/source3/lib/tdb_validate.c b/source3/lib/tdb_validate.c index 385f4d0ef81..e4f752023da 100644 --- a/source3/lib/tdb_validate.c +++ b/source3/lib/tdb_validate.c @@ -118,7 +118,7 @@ int tdb_validate(struct tdb_context *tdb, tdb_validate_data_func validate_fn) * just let the child panic. we catch the signal. */ DEBUG(10, ("tdb_validate: forking to let child do validation.\n")); - child_pid = sys_fork(); + child_pid = fork(); if (child_pid == 0) { /* child code */ DEBUG(10, ("tdb_validate (validation child): created\n")); diff --git a/source3/lib/util.c b/source3/lib/util.c index 9d3d787d639..7be056c68b0 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -860,7 +860,7 @@ void smb_panic_s3(const char *why) int result; DEBUG(0,("PANIC (pid %llu): %s\n", - (unsigned long long)sys_getpid(), why)); + (unsigned long long)getpid(), why)); log_stack_trace(); #if defined(HAVE_PRCTL) && defined(PR_SET_PTRACER) @@ -1985,7 +1985,7 @@ static uint32 my_vnn = NONCLUSTER_VNN; void set_my_vnn(uint32 vnn) { - DEBUG(10, ("vnn pid %d = %u\n", (int)sys_getpid(), (unsigned int)vnn)); + DEBUG(10, ("vnn pid %d = %u\n", (int)getpid(), (unsigned int)vnn)); my_vnn = vnn; } @@ -2013,7 +2013,7 @@ struct server_id pid_to_procid(pid_t pid) struct server_id procid_self(void) { - return pid_to_procid(sys_getpid()); + return pid_to_procid(getpid()); } bool procid_equal(const struct server_id *p1, const struct server_id *p2) @@ -2035,7 +2035,7 @@ bool cluster_id_equal(const struct server_id *id1, bool procid_is_me(const struct server_id *pid) { - if (pid->pid != sys_getpid()) + if (pid->pid != getpid()) return False; if (pid->task_id != 0) return False; |