Re: [patch] fishfs bugs


> > the first chunk is trivial: you check for got_interrupt but it is always a
> > non-zero number, actually the address of teh got_interrupt() function :))
> > you probably noticed that it doesn't work so that ! was removed :)
> > 
> > the second part is probably bug, i see no sense of checking for
> > got_interrupt() if interrupt check is disabled...
> First part is okay, but I have doubts about second


> one. disable_interrupt_key() has something to do ^c, IIRC.

disable_interrupt_key disables the SIGINT (ctrl^c) handler,
enable_interrupt_key enables it.
got_interrupt() returns 1 if ctrl^c was pressed since last call.
(the SIGINT handler (enabled by enable_interrupt_key) sets a flag
when user press ctrl^c, and this flag is query-able with got_interrupt)
it only works if ctrl^c is enabled at all (enable_interrupt_key),
so calling it after disable_interrupt_key has no sense.

A'rpi / Astral & ESP-team

Developer of MPlayer, the Movie Player for Linux -
    "However, many people beg for its inclusion in Debian. Why?" - Gabucino
  "Because having new software in Debian is good." - Josselin Mouette
"Because having good software in Debian is new." - Gabucino

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]