diff options
author | Nick Clifton <nickc@redhat.com> | 2016-10-17 10:26:56 +0100 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2016-10-17 10:26:56 +0100 |
commit | 41f225defe891ff71d3c8a149cdc1ed8f3a64c5c (patch) | |
tree | 57d39e6281cdc61994d24ce2ab8eed7d44fbd0e1 /libiberty/testsuite/test-pexecute.c | |
parent | b89bd142d2271fb9aeacb4d9e6fbabd842755039 (diff) | |
download | gdb-41f225defe891ff71d3c8a149cdc1ed8f3a64c5c.zip gdb-41f225defe891ff71d3c8a149cdc1ed8f3a64c5c.tar.gz gdb-41f225defe891ff71d3c8a149cdc1ed8f3a64c5c.tar.bz2 |
Sync libiberty sources with gcc mainline.
2016-09-19 Andrew Stubbs <ams@codesourcery.com>
* pex-win32.c (argv_to_cmdline): Quote zero-length parameters.
* testsuite/test-pexecute.c (main): Insert check for zero-length parameters.
2016-09-10 Mark Wielaard <mjw@redhat.com>
* cp-demangle.c (d_substitution): Change struct demangle_component
variable name from c to dc.
2016-08-12 Marek Polacek <polacek@redhat.com>
PR c/7652
* cp-demangle.c (d_print_mod): Add FALLTHRU.
2016-08-04 Marcel B?hme <boehme.marcel@gmail.com>
PR c++/71696
* cplus-dem.c: Prevent infinite recursion when there is a cycle
in the referencing of remembered mangled types.
(work_stuff): New stack to keep track of the remembered mangled
types that are currently being processed.
(push_processed_type): New method to push currently processed
remembered type onto the stack.
(pop_processed_type): New method to pop currently processed
remembered type from the stack.
(work_stuff_copy_to_from): Copy values of new variables.
(delete_non_B_K_work_stuff): Free stack memory.
(demangle_args): Push/Pop currently processed remembered type.
(do_type): Do not demangle a cyclic reference and push/pop
referenced remembered type.
Diffstat (limited to 'libiberty/testsuite/test-pexecute.c')
-rw-r--r-- | libiberty/testsuite/test-pexecute.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libiberty/testsuite/test-pexecute.c b/libiberty/testsuite/test-pexecute.c index 8e01fda..f62239d 100644 --- a/libiberty/testsuite/test-pexecute.c +++ b/libiberty/testsuite/test-pexecute.c @@ -285,6 +285,20 @@ main (int argc, char **argv) ERROR ("echo exit status failed"); pex_free (pex1); + /* Check empty parameters don't get lost. */ + pex1 = TEST_PEX_INIT (PEX_USE_PIPES, "temp"); + subargv[1] = "echo"; + subargv[2] = "foo"; + subargv[3] = ""; + subargv[4] = "bar"; + subargv[5] = NULL; + TEST_PEX_RUN (pex1, 0, "./test-pexecute", subargv, NULL, NULL); + e = TEST_PEX_READ_OUTPUT (pex1); + CHECK_LINE (e, "foo bar"); /* Two spaces! */ + if (TEST_PEX_GET_STATUS_1 (pex1) != 0) + ERROR ("echo exit status failed"); + pex_free (pex1); + pex1 = TEST_PEX_INIT (PEX_USE_PIPES, "temp"); subargv[1] = "echo"; subargv[2] = "bar"; |