All project content is available for reading, but you need to be a member of the project for Subversion checkout of source code, or to create/modify any information.
Login if you are a member. Apply here to request membership (open to all).

Ticket #248 (closed question: fixed)

Opened 7 years ago

Last modified 7 years ago

Global exception logged after 404Handler redirects

Reported by: magne.ingvaldsen@… Owned by: mari@…
Priority: minor Component: 404Handler
Keywords: Cc:


When the Custom404Handler performs the redirect, we get two events in our error log; "Global.Global_Error - 1.2.5 Unhandled exception in ASP.NET". I tried to catch the error in Application_Error in Global.asax, but GetLastError returns nothing. That might be because the error is cleared from the httpcontext in the 404Handler(?). This could be related only to our environment, or is this a know issue? This is not a big problem, but it creates a lot of noise in our error logs.

Change History

comment:1 Changed 7 years ago by per.magne.skuseth@…

A possible fix for this would be to set the HttpCurrent.Context to null at the bottom at the PerformRedirect method (in Custom404Handler.cs), which would cause the Global_Error to exit before the logging occurs.

comment:2 Changed 7 years ago by mari@…

Fixed in changeset [2052] - using solution specified above. New and updated module package available on the module download page

comment:3 Changed 7 years ago by mari@…

  • Status changed from new to closed
  • Resolution set to fixed
Note: See HelpUser/Tickets for help on using tickets.