aboutsummaryrefslogtreecommitdiff
path: root/tests/tforlan.c
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2012-10-01 16:43:18 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2012-10-01 16:58:20 +0300
commitddb280198adcada561b8e72c79b92d50a05b3e78 (patch)
treede6f2d47fe10d0fb37279893d17ffcbd30b156ce /tests/tforlan.c
parent78b25d9756403fef919684738f7aecb2cdcee465 (diff)
downloadeclat-ddb280198adcada561b8e72c79b92d50a05b3e78.tar.gz
eclat-ddb280198adcada561b8e72c79b92d50a05b3e78.tar.bz2
Implement exit; add some docs.
* Makefile.am (SUBDIRS): Add doc. * configure.ac: Build doc/Makefile * doc/Makefile.am: New file. * doc/eclat-associate-address.1: New file. * doc/eclat.1: New file. * etc/associate-address.fln: Call exit if the request fails. * etc/default.fln: Call exit if error is returned or if the response is not recognized. * lib/forlan.c (forlan_eval_env) <exit_code>: New member. New built-in function: exit. (forlan_run): Return exit code. * lib/forlan.h (forlan_run): Change return type. * lib/forlanlex.l: Treat unquoted decimal number as a quoted string. * src/asscaddr-cl.opt: Minor changes. * src/cmdline.opt: Minor changes. * src/eclat.c: Return EX_NOPERM on unsufficient permissions to open the configuration file. * tests/exit.at: New file. * tests/Makefile.am: Add new files. * tests/testsuite.at: Include new test cases. * tests/tforlan.c: Propagate the return from forlan_run to the shell.
Diffstat (limited to 'tests/tforlan.c')
-rw-r--r--tests/tforlan.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/tforlan.c b/tests/tforlan.c
index 403438e..64f84e1 100644
--- a/tests/tforlan.c
+++ b/tests/tforlan.c
@@ -176,13 +176,14 @@ main(int argc, char **argv)
if (options & OPT_SORT)
grecs_tree_sort(tree, node_ident_cmp);
- forlan_run(env, tree);
+ rc = forlan_run(env, tree);
grecs_tree_free(tree);
- }
+ } else
+ rc = 0;
forlan_free_environment(env);
- return 0;
+ return rc;
}

Return to:

Send suggestions and report system problems to the System administrator.