summaryrefslogtreecommitdiffstats
path: root/common/os_calls.c
diff options
context:
space:
mode:
authorjsorg71 <jsorg71>2005-08-14 02:23:20 +0000
committerjsorg71 <jsorg71>2005-08-14 02:23:20 +0000
commitb51098f5212b41832578f523df77a80c0bd4236f (patch)
tree2b90c0e31cc47a645977400966ed0cc28c98e468 /common/os_calls.c
parentc3ff1bcebbe08abbd64067209e388a91dbc402c3 (diff)
downloadxrdp-proprietary-b51098f5212b41832578f523df77a80c0bd4236f.tar.gz
xrdp-proprietary-b51098f5212b41832578f523df77a80c0bd4236f.zip
add pos and unset_signals funcs
Diffstat (limited to 'common/os_calls.c')
-rw-r--r--common/os_calls.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/common/os_calls.c b/common/os_calls.c
index 838e60ec..6b90ffc9 100644
--- a/common/os_calls.c
+++ b/common/os_calls.c
@@ -674,6 +674,20 @@ g_atoi(char* str)
}
/*****************************************************************************/
+int
+g_pos(char* str, char* to_find)
+{
+ char* pp;
+
+ pp = strstr(str, to_find);
+ if (pp == 0)
+ {
+ return -1;
+ }
+ return (pp - str);
+}
+
+/*****************************************************************************/
long
g_load_library(char* in)
{
@@ -780,6 +794,16 @@ g_signal_child_stop(void (*func)(int))
}
/*****************************************************************************/
+void
+g_unset_signals(void)
+{
+ sigset_t mask;
+
+ sigemptyset(&mask);
+ sigprocmask(SIG_SETMASK, &mask, NULL);
+}
+
+/*****************************************************************************/
int
g_fork(void)
{