This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v6 3/3] MI: tests for -catch-load/-catch-unload


>>>>> "Mircea" == Mircea Gherzan <mircea.gherzan@intel.com> writes:

Mircea> +mi_gdb_test "333-exec-continue" ".*" "catch-unload: run"
Mircea> +
Mircea> +gdb_expect {
Mircea> +    -re ".*stopped.*reason=\"solib-event\".*removed=.*\r\n.*\r\n$mi_gdb_prompt$" {
Mircea> +        pass "catch-unload: solib-event stop"
Mircea> +    }
Mircea> +    -re ".*\r\n$mi_gdb_prompt$" {
Mircea> +        fail "catch-unload: solib-event stop"
Mircea> +    }
Mircea> +    timeout {
Mircea> +        fail "(timeout) catch-unload: solib-event stop"
Mircea> +    }
Mircea> +}

I am not sure but this kind of thing seems racy to me.
Can't that ".*" in the mi_gdb_test suck up an arbitrary amount of gdb
output, perhaps enough to cause gdb_expect not to see the data it needs
to match?
I think some other approach is needed.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]