git.annexia.org
/
whenjobs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Prevent users from setting JOBSERIAL and from setting variables with invalid names.
[whenjobs.git]
/
tools
/
whenjobs.ml
diff --git
a/tools/whenjobs.ml
b/tools/whenjobs.ml
index
0810649
..
60795ba
100644
(file)
--- a/
tools/whenjobs.ml
+++ b/
tools/whenjobs.ml
@@
-296,7
+296,13
@@
and set_variable name value typ =
) in
let client = start_client () in
) in
let client = start_client () in
- Whenproto_clnt.When.V1.set_variable client (name, value);
+ (match Whenproto_clnt.When.V1.set_variable client (name, value) with
+ | `ok -> ()
+ | `error msg ->
+ eprintf "whenjobs: set: %s\n" msg;
+ suggest_check_server_logs ();
+ exit 1
+ );
stop_client client
and get_variable name =
stop_client client
and get_variable name =