This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb/gdb-8.1-branch] [gdbserver/win32] fatal "glob could not process pattern '(null)'" error
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Thu, 10 May 2018 14:50:07 -0400
- Subject: [binutils-gdb/gdb-8.1-branch] [gdbserver/win32] fatal "glob could not process pattern '(null)'" error
*** TEST RESULTS FOR COMMIT e378993dd341b10571a7cb6e98d5d3b48a06e24c ***
Author: Joel Brobecker <brobecker@adacore.com>
Branch: gdb-8.1-branch
Commit: e378993dd341b10571a7cb6e98d5d3b48a06e24c
[gdbserver/win32] fatal "glob could not process pattern '(null)'" error
Trying to start GDBserver on Windows currently yields the following
error...
$ gdbserver.exe --once :4444 simple_main.exe
glob could not process pattern '(null)'.
Exiting
... after which GDB terminates with a nonzero status.
This is because create_process in win32-low.c calls gdb_tilde_expand
with the result of a call to get_inferior_cwd without verifying that
the returned directory is not NULL:
| static BOOL
| create_process (const char *program, char *args,
| DWORD flags, PROCESS_INFORMATION *pi)
| {
| const char *inferior_cwd = get_inferior_cwd ();
| std::string expanded_infcwd = gdb_tilde_expand (inferior_cwd);
This patch avoids this by only calling gdb_tilde_expand when
INFERIOR_CWD is not NULL, which is similar to what is done on
GNU/Linux for instance.
gdb/gdbserver/ChangeLog:
PR server/23158:
* win32-low.c (create_process): Only call gdb_tilde_expand if
inferior_cwd is not NULL.
- Follow-Ups:
- Failures on Fedora-s390x-m64, branch gdb-8.1-branch
- Failures on RHEL-s390x-m64, branch gdb-8.1-branch
- Failures on Debian-s390x-native-extended-gdbserver-m64, branch gdb-8.1-branch
- Failures on Debian-s390x-native-gdbserver-m64, branch gdb-8.1-branch
- Failures on Fedora-x86_64-m64, branch gdb-8.1-branch
- Failures on Fedora-i686, branch gdb-8.1-branch
- Failures on Fedora-x86_64-cc-with-index, branch gdb-8.1-branch
- Failures on Fedora-x86_64-native-extended-gdbserver-m64, branch gdb-8.1-branch
- Failures on Fedora-x86_64-native-gdbserver-m64, branch gdb-8.1-branch
- Failures on Ubuntu-AArch32-native-extended-gdbserver-m32, branch gdb-8.1-branch
- Failures on Ubuntu-AArch32-native-gdbserver-m32, branch gdb-8.1-branch
- Failures on Ubuntu-AArch32-m32, branch gdb-8.1-branch