aboutsummaryrefslogtreecommitdiff
path: root/src/util.c
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2012-12-10 17:40:21 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2012-12-10 17:40:21 +0200
commit980d465d9ea87e2123bd9a3045de5c0a45e84cd7 (patch)
treeb7de616658bd27bfed159bcb82a43d71721df6da /src/util.c
parent5a7b73860974384d8e00065105435403b0842ab0 (diff)
downloadeclat-980d465d9ea87e2123bd9a3045de5c0a45e84cd7.tar.gz
eclat-980d465d9ea87e2123bd9a3045de5c0a45e84cd7.tar.bz2
Implement attach-volume and detach-volume
* TODO: Update * etc/attach-volume.fln: New file. * etc/detach-volume.fln: New file. * etc/Makefile.am: Add new files. * src/attvol.c: New file. * src/detvol-cl.opt: New file. * src/detvol.c: New file. * src/Makefile.am: Add new files. * src/eclat.c: Add new commands. * src/eclat.h: Add new protos. * src/util.c (translate_ids) (translate_resource_ids): Do nothing id argc is 0.
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util.c b/src/util.c
index b4af99f..15d60f5 100644
--- a/src/util.c
+++ b/src/util.c
@@ -28,7 +28,7 @@ translate_ids(int argc, char **argv, const char *mapname)
struct eclat_map *map;
char *val;
- if (!translate_option)
+ if (!translate_option || argc == 0)
return;
if (custom_map)
mapname = custom_map;
@@ -72,7 +72,7 @@ translate_resource_ids(int argc, char **argv)
struct wordsplit ws;
int wsflags = WRDSF_DEFFLAGS|WRDSF_DELIM;
- if (!translate_option)
+ if (!translate_option || argc == 0)
return;
ws.ws_delim = ",";
for (i = 0; i < argc; i++) {

Return to:

Send suggestions and report system problems to the System administrator.