From: Adam Dickmeiss Date: Wed, 17 Aug 2011 13:50:11 +0000 (+0200) Subject: zoomsh: fix SEGV for set command wo value X-Git-Tag: v4.2.9~1 X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=commitdiff_plain;h=4b92edda23ae263000414a98e037c5b9c226dd5f;hp=86bfbf5acd6fd03bc1d483cdd6cc1f8ba30da6c4 zoomsh: fix SEGV for set command wo value --- diff --git a/zoom/zoomsh.c b/zoom/zoomsh.c index fea2181..2126f30 100644 --- a/zoom/zoomsh.c +++ b/zoom/zoomsh.c @@ -120,7 +120,7 @@ static void cmd_set(ZOOM_connection *c, ZOOM_resultset *r, return ; } val_len = next_token_chars(args, &val_buf, ""); - if (val_len) + if (val_len != -1) ZOOM_options_setl(options, wrbuf_cstr(key), val_buf, val_len); else ZOOM_options_set(options, wrbuf_cstr(key), 0);