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: RFC: Do not call write_pc for "signal SIGINT"


Daniel Jacobowitz wrote:
On Thu, Aug 28, 2008 at 11:09:56AM -0700, Michael Snyder wrote:
Hmmm, kind of opaque.  Your new code seems like the right
thing to do, but I don't understand the code that you're replacing.

Isn't -1 supposed to mean the same as stop_pc?

Except that we call gdbarch_write_pc to replace the PC in this case, and that has side effects - take a look at a Linux example.

And isn't signal 0 equivalent to no signal?

Yes, that's right.


This isn't the only place where Linux's internal errno codes can leak
back into user programs because of how we fiddle orig_eax.  I'll file
another bug report about that.
Now you've really lost me.  What have errno codes
got to do with this?

Sorry, take a look at the PR (gdb/2241) for more information. When you hit C-c during select, and then type "signal SIGINT", the program gets errno 514 instead of EINTR.

Yes, I know, I need a testcase...

More than a testcase. This isn't very well explained. You didn't reference the PR in your original post, and I'm still not sure how we're getting from SIGINT to signal 0...


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