projects
/
project
/
luci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
82858a8
)
nixio: chdir()
author
Steven Barth
<steven@midlink.org>
Thu, 12 Mar 2009 21:44:11 +0000
(21:44 +0000)
committer
Steven Barth
<steven@midlink.org>
Thu, 12 Mar 2009 21:44:11 +0000
(21:44 +0000)
libs/nixio/src/process.c
patch
|
blob
|
history
diff --git
a/libs/nixio/src/process.c
b/libs/nixio/src/process.c
index 65d6209008f437e5a3570b52c981accd3f119a76..a82e5660d098790f5716984ac3b1d1cb318bdb4e 100644
(file)
--- a/
libs/nixio/src/process.c
+++ b/
libs/nixio/src/process.c
@@
-174,6
+174,10
@@
static int nixio_setsid(lua_State *L) {
}
}
+static int nixio_chdir(lua_State *L) {
+ return nixio__pstatus(L, !chdir(luaL_checkstring(L, 1)));
+}
+
/* module table */
static const luaL_reg R[] = {
@@
-181,6
+185,7
@@
static const luaL_reg R[] = {
{"wait", nixio_wait},
{"kill", nixio_kill},
{"nice", nixio_nice},
+ {"chdir", nixio_chdir},
{"getpid", nixio_getpid},
{"getppid", nixio_getppid},
{"getuid", nixio_getuid},