This is the mail archive of the 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: [RFC 3/6] mingw-hdep: Add "maint set testuite-mode on/off" command.

On 2013-9-27 4:01, Pierre Muller wrote:
> This patch is to add
> maint set testsuite mode on/off
> command.
>   Finally, thanks to Yao's patch about handling of flushing of
> stderr for mingw, it reduces to switching the
> stdout and stderr between binary and text mode.
> ---
>  gdb/mingw-hdep.c |   58
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  1 files changed, 58 insertions(+), 0 deletions(-)
> diff --git a/gdb/mingw-hdep.c b/gdb/mingw-hdep.c
> index 976e9e8..330f46b 100644
> --- a/gdb/mingw-hdep.c
> +++ b/gdb/mingw-hdep.c
> @@ -21,6 +21,8 @@
>  #include "main.h"
>  #include "serial.h"
>  #include "event-loop.h"
> +#include "command.h"
> +#include "gdbcmd.h"
>  #include "gdb_assert.h"
>  #include "gdb_select.h"
> @@ -274,6 +276,50 @@ gdb_call_async_signal_handler (struct
> async_signal_handler *handler,
>    SetEvent (sigint_event);
>  }

I failed to apply this patch:
Here is the log:

zyh23@ZYH /f/build_gdb/gdb/gdbgit/gdb (my_build)
$ git am ../patches/muller/*.eml
Applying: Fix display of tabulation character for mingw hosts.
Applying: Avoid missing char before incomplete sequence in wchar_iterate.
Applying: mingw-hdep: Add "maint set testuite-mode on/off" command.
fatal: corrupt patch at line 20
Patch failed at 0003 mingw-hdep: Add "maint set testuite-mode on/off" command.
The copy of the patch that failed is found in:
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

I just look at the line around 274, it is:

gdb_call_async_signal_handler (struct async_signal_handler *handler,
			       int immediate_p)
  if (immediate_p)
    sigint_handler = handler;
      mark_async_signal_handler (handler);
      sigint_handler = NULL;
  SetEvent (sigint_event);

/* -Wmissing-prototypes */
extern initialize_file_ftype _initialize_mingw_hdep;

So, I can't find the line in your patch
> @@ -274,6 +276,50 @@ gdb_call_async_signal_handler (struct
> async_signal_handler *handler,

Oh, I found that this line (function name and its parameter get wrapped)....
I fix those kind of errors by manually editing those eml files.

Besides that, the last patch, I see the email title have a CRLF after the word "PATCH", so when applied, I see the log message is lost.

So, Sending those patches as attachment should not have such problem.


Yuanhui Zhang

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