diff options
author | gramanas <anastasis.gramm2@gmail.com> | 2018-10-03 16:57:06 +0300 |
---|---|---|
committer | gramanas <anastasis.gramm2@gmail.com> | 2018-10-03 16:57:06 +0300 |
commit | bc2899dd69fce0f1868dbfad3394ef8b3dc48069 (patch) | |
tree | d6237ac42ea12a34ceb08117685c3fcbe5136d59 /src/actionhelper.c | |
parent | 1cfbedd0b199d77ed53e5224435a76978875e2fb (diff) | |
download | ck-bc2899dd69fce0f1868dbfad3394ef8b3dc48069.tar.gz ck-bc2899dd69fce0f1868dbfad3394ef8b3dc48069.tar.bz2 ck-bc2899dd69fce0f1868dbfad3394ef8b3dc48069.zip |
Basic delete
Diffstat (limited to 'src/actionhelper.c')
-rw-r--r-- | src/actionhelper.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/actionhelper.c b/src/actionhelper.c index 596a7db..667b898 100644 --- a/src/actionhelper.c +++ b/src/actionhelper.c @@ -82,8 +82,7 @@ AddOpt add_make_options(cklist *args) { DelOpt del_make_options(cklist *args) { list_rewind(args); DelOpt delOpt = { - .prog = NULL, - .path = "", + .arg = NULL, .isConf = 0, .err = DEL_NO_ERR }; @@ -94,13 +93,13 @@ DelOpt del_make_options(cklist *args) { delOpt.err = DEL_ERR_WRONG_ARGS; return delOpt; } - realpath(list_get(args), delOpt.path); - if (!util_is_file_rw(delOpt.path)) { + delOpt.arg = list_get(args); + if (!util_is_file_rw(delOpt.arg)) { delOpt.err = DEL_ERR_WRONG_PATH; return delOpt; } } else { - delOpt.prog = list_get(args); + delOpt.arg = list_get(args); } list_rewind(args); |