diff options
author | Martin Michlmayr <tbm@cyrius.com> | 2019-02-05 08:27:25 -0500 |
---|---|---|
committer | Martin Michlmayr <tbm@cyrius.com> | 2019-02-05 08:27:25 -0500 |
commit | 0bbb976ee3064ff59b319e30fd97e31020259760 (patch) | |
tree | 5d13986511c18d911b0d1b2dc498b0f81d3a3b0e /src/option.cc | |
parent | 9de94d4adb7a566af38814f9d37e26c559b68b4f (diff) | |
parent | 7a5871d3b53e66ee261bea4b41512e99269b18b1 (diff) | |
download | fork-ledger-0bbb976ee3064ff59b319e30fd97e31020259760.tar.gz fork-ledger-0bbb976ee3064ff59b319e30fd97e31020259760.tar.bz2 fork-ledger-0bbb976ee3064ff59b319e30fd97e31020259760.zip |
Merge branch 'next' into release/3.1.2
Diffstat (limited to 'src/option.cc')
-rw-r--r-- | src/option.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/option.cc b/src/option.cc index ab6c37e0..81f9af5b 100644 --- a/src/option.cc +++ b/src/option.cc @@ -42,6 +42,11 @@ namespace { { char buf[128]; char * p = buf; + + if (name.length() > 127) { + throw_(option_error, _f("Illegal option --%1%") % name); + } + foreach (char ch, name) { if (ch == '-') *p++ = '_'; |