This is the mail archive of the gdb-patches@sources.redhat.com 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: fix file descripter mapping for sim_callback->close et al


I've found that I've missed actually marking the file descriptors as free
on startup.  I've checked the attached on-liner in as an obvious fix.

2004-06-27  J"orn Rennecke <joern.rennecke@superh.com>

	* callback.c (os_shutdown): Fix bug in last change: actually
	mark file descriptors as available on startup.

Index: callback.c
===================================================================
RCS file: /cvs/src/src/sim/common/callback.c,v
retrieving revision 1.9
diff -p -r1.9 callback.c
*** callback.c	25 Jun 2004 16:48:03 -0000	1.9
--- callback.c	27 Jun 2004 03:12:42 -0000
*************** os_shutdown (p)
*** 453,458 ****
--- 453,459 ----
  	  /* At the initial call of os_init, we got -1, 0, 0, 0, ...  */
  	  if (next < 0)
  	    {
+ 	      p->fd_buddy[i] = -1;
  	      do_close = 0;
  	      break;
  	    }


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