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] serial, mdebugread, top.c, utils, frame.c: remove unused variables


On Fri, 07 May 2010 02:50:22 +0200, Michael Snyder wrote:
>  static void
>  do_fclose_cleanup (void *arg)
>  {
> -  FILE *file = arg;
>    fclose (arg);
>  }

I believe the intentional was rather `fclose (file);' according to the general
GDB template of callback functions:

void
func (void *arg)
{
  real_type *var = arg;
  
  Use VAR having it type-checked callee prototypes or real_type changes.
}

But I understand it is a nitpick for never-changing FILE * and fclose.


Regards,
Jan


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