Menu

#69 Fix logger for long-lived clients, was: "#2347 Don't spawn logger for clients"

1.4.6
fixed
None
None
Leak
2013-10-02
2013-08-08
No

See also https://sourceforge.net/p/sblim/bugs/2347 (but its closed and I can't re-open it)

The problem is with closeLogging() done by SfcbLocal and the call to startLogging() on the next request. startLogging does not re-open the closed fds and thus operates on stale file descriptors in logfds.

Fix attached. It re-opens the pipe, giving ownership of logfds back to SfcbLocal.

1 Attachments
x

Related

Bugs: #2726

Discussion

  • Klaus Kämpf

    Klaus Kämpf - 2013-08-08

    Here's a better patch without the overhead of calling pipe(). It calls closeLogging() with the same 'thread' parameter as startLogging() and closes the logfds[1] only if it was actually opened by startLogging before,

     
  • Klaus Kämpf

    Klaus Kämpf - 2013-08-08

    Patch above is against 1.3.11 !

     
  • Klaus Kämpf

    Klaus Kämpf - 2013-08-08

    Apparently, SfcbLocal in 1.4.x does not call startLogging() any more. But it still calls closeLogging() ?!

    Patch for 1.4 (git head) attached

     
  • Chris Buccella

    Chris Buccella - 2013-09-18
    • assigned_to: Chris Buccella
     
  • Chris Buccella

    Chris Buccella - 2013-09-18

    1.4 commit [66e4ab]
    1.3 commit [b6344b]

     

    Related

    Commit: [66e4ab]
    Commit: [b6344b]


    Last edit: Chris Buccella 2013-09-18
  • Chris Buccella

    Chris Buccella - 2013-09-18
    • status: open --> pending
    • Release: backlog --> 1.4.6
     
  • Dave Heller

    Dave Heller - 2013-10-02
    • Status: pending --> fixed
     

Log in to post a comment.