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: [RFA] Remove cleanups from ser-mingw.c


Hi Tom,

LGTM, with some nits.

On 2018-06-14 05:20 PM, Tom Tromey wrote:
> @@ -914,14 +913,12 @@ pipe_windows_open (struct serial *scb, const char *name)
>      goto fail;
>    scb->error_fd = fileno (pex_stderr);
>  
> -  scb->state = (void *) ps;
> +  scb->state = (void *) ps.release ();

- I think we could remove the cast, unless you think it helps readability.
- I think we could remove the goto fail mechanism now.

>  
>    argv.release ();

Side note: doesn't this argv.release() look fishy to you?  Who ends up owning it?

Simon


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