diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
commit | a86c5f7cae7ec9a3398300555a0b644689d946a1 (patch) | |
tree | 39fe4b107c71174fd1e8a8ceb9a4d2aa14116248 /tools/lemon | |
parent | Releasing progress-linux version 4.2.6-1~progress7.99u1. (diff) | |
download | wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.tar.xz wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.zip |
Merging upstream version 4.4.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tools/lemon')
-rw-r--r-- | tools/lemon/CMakeLists.txt | 2 | ||||
-rw-r--r-- | tools/lemon/lemon.c | 3 | ||||
-rw-r--r-- | tools/lemon/patches/01-lemon-dashdash.patch | 14 |
3 files changed, 18 insertions, 1 deletions
diff --git a/tools/lemon/CMakeLists.txt b/tools/lemon/CMakeLists.txt index 529eeae1..b7ba7543 100644 --- a/tools/lemon/CMakeLists.txt +++ b/tools/lemon/CMakeLists.txt @@ -12,6 +12,8 @@ add_executable(lemon lemon.c) if(DEFINED LEMON_C_COMPILER) set(CMAKE_C_COMPILER "${LEMON_C_COMPILER}") set(CMAKE_C_FLAGS "") + set(CMAKE_EXE_LINKER_FLAGS "") + set(CMAKE_SYSROOT "") endif() # To keep lemon.c as close to upstream as possible disable all warnings diff --git a/tools/lemon/lemon.c b/tools/lemon/lemon.c index 869ac580..c4b48811 100644 --- a/tools/lemon/lemon.c +++ b/tools/lemon/lemon.c @@ -2106,6 +2106,7 @@ int OptInit(char **a, struct s_options *o, FILE *err) if( g_argv && *g_argv && op ){ int i; for(i=1; g_argv[i]; i++){ + if( strcmp(g_argv[i],"--")==0 ) break; if( g_argv[i][0]=='+' || g_argv[i][0]=='-' ){ errcnt += handleflags(i,err); }else if( strchr(g_argv[i],'=') ){ @@ -5847,7 +5848,7 @@ int Configtable_insert(struct config *data) newnp->from = &(array.ht[h]); array.ht[h] = newnp; } - /* free(x4a->tbl); // This code was originall written for 16-bit machines. + /* free(x4a->tbl); // This code was originally written for 16-bit machines. ** on modern machines, don't worry about freeing this trival amount of ** memory. */ *x4a = array; diff --git a/tools/lemon/patches/01-lemon-dashdash.patch b/tools/lemon/patches/01-lemon-dashdash.patch new file mode 100644 index 00000000..1c204574 --- /dev/null +++ b/tools/lemon/patches/01-lemon-dashdash.patch @@ -0,0 +1,14 @@ +Don't try to parse flags and options that are after "--". This makes it +possible to prevent a filename path with an '=' in it from being processed +as an option. +SPDX-License-Identifier: CC0-1.0 +--- a/lemon.c ++++ b/lemon.c +@@ -2106,6 +2106,7 @@ int OptInit(char **a, struct s_options *o, FILE *err) + if( g_argv && *g_argv && op ){ + int i; + for(i=1; g_argv[i]; i++){ ++ if( strcmp(g_argv[i],"--")==0 ) break; + if( g_argv[i][0]=='+' || g_argv[i][0]=='-' ){ + errcnt += handleflags(i,err); + }else if( strchr(g_argv[i],'=') ){ |