summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Grenville <pyxlcy@gmail.com>2012-09-11 23:11:23 +0800
committerRichard Grenville <pyxlcy@gmail.com>2012-09-11 23:11:23 +0800
commit0c077a76d1a8ce50e889c2caa31815c59926bda3 (patch)
tree6a0048871a758b283e036fae648a5593ac0e89e1
parent00d29b07488415661f9306b9cd5fffc855c9c358 (diff)
downloadtdebase-0c077a76.tar.gz
tdebase-0c077a76.zip
Bug fix: Segfault when encountering invalid long option
I didn't read the documentation of getopt_long() carefully.
-rw-r--r--compton.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/compton.c b/compton.c
index 9e1eef336..a281b31b3 100644
--- a/compton.c
+++ b/compton.c
@@ -2594,6 +2594,8 @@ main(int argc, char **argv) {
{ "shadow-green", required_argument, NULL, 0 },
{ "shadow-blue", required_argument, NULL, 0 },
{ "inactive-opacity-override", no_argument, NULL, 0 },
+ // Must terminate with a NULL entry
+ { NULL, 0, NULL, 0 },
};
XEvent ev;