Uploaded image for project: 'mod_python'
  1. mod_python
  2. MODPYTHON-41

Calls to PyErr_Print should be followed by fflush().

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.1.4
    • 3.2.7
    • core
    • None

    Description

      In mod_python.c there are a few places where PyErr_Print() is called. The output of this
      function is sent to stderr and not to the Apache log functions. The output does make its
      way into the Apache error log file eventually, but not straight away due to buffering
      issues. In order to ensure the output gets the logs straight away, a call should be made
      to fflush(stderr) after calling PyErr_Print(). Ie.,

      PyErr_Print();
      fflush(stderr);

      This will ensure that relevant lower level Python errors appear adjacent to any error message
      logged by mod_python to the error log file.

      Attachments

        Activity

          People

            nlehuen Nicolas Lehuen
            grahamd Graham Phillip Dumpleton
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: