aboutsummaryrefslogtreecommitdiff
path: root/slof/fs/node.fs
diff options
context:
space:
mode:
authorThomas Huth <thuth@linux.vnet.ibm.com>2011-02-07 16:27:56 +0100
committerThomas Huth <thuth@linux.vnet.ibm.com>2011-03-22 15:22:09 +0100
commit7a698c473408a85fc026f653b50dc3b48badd88b (patch)
tree84e424bb7b2db6c63c6e6b201f1df0b69b59128c /slof/fs/node.fs
parentf246a4c0a5e763fd6cfffc78585897948df25bbe (diff)
downloadSLOF-7a698c473408a85fc026f653b50dc3b48badd88b.zip
SLOF-7a698c473408a85fc026f653b50dc3b48badd88b.tar.gz
SLOF-7a698c473408a85fc026f653b50dc3b48badd88b.tar.bz2
Fixed a bug in the set-alias command
set-alias did not clean up the stack in case the "/aliases" node coud not be found. Signed-off-by: Thomas Huth <thuth@linux.vnet.ibm.com>
Diffstat (limited to 'slof/fs/node.fs')
-rw-r--r--slof/fs/node.fs7
1 files changed, 6 insertions, 1 deletions
diff --git a/slof/fs/node.fs b/slof/fs/node.fs
index 8f587b2..085cd9d 100644
--- a/slof/fs/node.fs
+++ b/slof/fs/node.fs
@@ -226,7 +226,12 @@ CREATE $indent 100 allot VARIABLE indent 0 indent !
defer find-node
: set-alias ( alias-name len device-name len -- )
encode-string
- 2swap s" /aliases" find-node dup IF set-property ELSE drop THEN ;
+ 2swap s" /aliases" find-node ?dup IF
+ set-property
+ ELSE
+ 4drop
+ THEN
+;
: find-alias ( alias-name len -- false | dev-path len )
s" /aliases" find-node dup IF