mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-25 13:27:26 +08:00
Fix py-parameter.exp and scm-parameter.exp path matching
gdb/testsuite/ChangeLog: * gdb.python/py-parameter.exp: * gdb.guile/scm-parameter.exp: Escape the path that we are matching against, as it might contain characters that are special to regular expressions.
This commit is contained in:
@ -32,7 +32,8 @@ if { [is_remote host] } {
|
||||
# doesn't set search directories on remote host.
|
||||
set directories ".*\\\$cdir.\\\$cwd"
|
||||
} else {
|
||||
set directories "$srcdir/$subdir.\\\$cdir.\\\$cwd"
|
||||
set escaped_directory [string_to_regexp "$srcdir/$subdir"]
|
||||
set directories "$escaped_directory.\\\$cdir.\\\$cwd"
|
||||
}
|
||||
gdb_test "python print (gdb.parameter ('directories'))" $directories
|
||||
|
||||
|
Reference in New Issue
Block a user