Simplify windows-nat.c::get_module_name
authorJoel Brobecker <brobecker@adacore.com>
Mon, 3 Feb 2014 11:10:48 +0000 (06:10 -0500)
committerJoel Brobecker <brobecker@adacore.com>
Thu, 20 Feb 2014 08:43:03 +0000 (09:43 +0100)
commit47f7ffdb18d09177068d1252538395feb7ca09ec
treed2dc43f458319431646594aa56fa1689fb646aad
parent1cd9feab11bb859cd737afc553e0d6073454bdd2
Simplify windows-nat.c::get_module_name

Now that get_module_name is no longer called for handling DLL events,
we can simplify it a bit, knowing that the only use is to get the
executable's filename.

While doing so, we adjusted the implementation a bit to avoid
references to DLLs, renamed it to make its more-targeted usage
more explicit, moved it right before the only function that uses it.
We also remove the use of hard-coded length for the buffers being
used.

gdb/ChangeLog:

* windows-nat.c (get_module_name): Delete.
(windows_get_exec_module_filename): New function, mostly
inspired from get_module_name.
(windows_pid_to_exec_file): Replace call to get_module_name
by call to windows_get_exec_module_filename.
gdb/ChangeLog
gdb/windows-nat.c
This page took 0.026297 seconds and 4 git commands to generate.