diff options
author | Volker Lendecke <vlendec@samba.org> | 2006-07-16 06:32:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:38:10 -0500 |
commit | 95fd775e815e797534881c4f8d6e395669652037 (patch) | |
tree | 36eb1d7b6b649f33a59578640be8d37da13561d2 /source3 | |
parent | d2b11041b23f588b0f5baa1165e15b8cebb50dba (diff) | |
download | samba-95fd775e815e797534881c4f8d6e395669652037.tar.gz samba-95fd775e815e797534881c4f8d6e395669652037.tar.bz2 samba-95fd775e815e797534881c4f8d6e395669652037.zip |
r17077: Activate RPC-SAMBA3-GETUSERNAME in the build farm
(This used to be commit 8c6088f2bd0a5e3a854a31fe428d841d61055a30)
Diffstat (limited to 'source3')
-rwxr-xr-x | source3/script/tests/test_posix_s3.sh | 2 | ||||
-rw-r--r-- | source3/utils/net.c | 36 |
2 files changed, 37 insertions, 1 deletions
diff --git a/source3/script/tests/test_posix_s3.sh b/source3/script/tests/test_posix_s3.sh index 1fce6455fe..08aa043358 100755 --- a/source3/script/tests/test_posix_s3.sh +++ b/source3/script/tests/test_posix_s3.sh @@ -34,7 +34,7 @@ raw="$raw RAW-SFILEINFO RAW-SFILEINFO-BUG RAW-STREAMS RAW-UNLINK RAW-WRITE" raw="$raw RAW-SAMBA3HIDE RAW-SAMBA3BADPATH" rpc="RPC-AUTHCONTEXT RPC-BINDSAMBA3 RPC-NETLOGSAMBA3 RPC-SAMBA3SESSIONKEY" -rpc="$rpc RPC-SAMBA3-SRVSVC" +rpc="$rpc RPC-SAMBA3-SRVSVC RPC-SAMBA3-GETUSERNAME" tests="$base $raw $rpc" diff --git a/source3/utils/net.c b/source3/utils/net.c index 8b4fb042fc..b09b46d6af 100644 --- a/source3/utils/net.c +++ b/source3/utils/net.c @@ -796,9 +796,45 @@ static int net_maxrid(int argc, const char **argv) return 0; } +#include "/data/pth-2.0.7/include/pth.h" + +static void *thread_routine(void *arg) +{ + d_printf("In thread\n"); + return arg; +} + +static int net_pthtest(int argc, const char **argv) +{ + int res; + void *x; + pth_t t; + pth_attr_t t_attr; + + if ((res = pth_init()) < 0) { + d_printf("pth_init failed: %d\n", res); + return -1; + } + + t_attr = pth_attr_new(); + + if (!(t = pth_spawn(t_attr, thread_routine, &res))) { + d_printf("pth_spawn failed\n"); + return -1; + } + + if ((res = pth_join(t, &x)) < 0) { + d_printf("pth_join failed\n"); + return -1; + } + + return 0; +} + /* main function table */ static struct functable net_func[] = { {"RPC", net_rpc}, + {"PTH", net_pthtest}, {"RAP", net_rap}, {"ADS", net_ads}, |