projects
/
melted
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
Remove OS/X warning re: get_string
[melted]
/
src
/
miracle
/
miracle_commands.c
diff --git
a/src/miracle/miracle_commands.c
b/src/miracle/miracle_commands.c
index
4bb0df3
..
178f7f9
100644
(file)
--- a/
src/miracle/miracle_commands.c
+++ b/
src/miracle/miracle_commands.c
@@
-211,7
+211,7
@@
response_codes miracle_set_global_property( command_argument cmd_arg )
strncpy( cmd_arg->root_dir, value, 1023 );
/* add a trailing slash if needed */
- if ( cmd_arg->root_dir[ len - 1 ] != '/')
+ if ( len && cmd_arg->root_dir[ len - 1 ] != '/')
{
cmd_arg->root_dir[ len ] = '/';
cmd_arg->root_dir[ len + 1 ] = '\0';