Error executing child request Sitecore

<!-- USE SERVER-SIDE REDIRECT FOR REQUEST ERRORS
If true, Sitecore will use Server.Transfer instead of Response.Redirect to redirect request to service pages
when an error occurs (item not found, access denied etc).
Default value: false
-->
<setting name="RequestErrors.UseServerSideRedirect" value="true"/>

Sitecore uses HttpContext.Current.Server.Transfer instead of HttpContext.Current.Server.TransferRequest so if you have UseServerSideRedirect set to “true” then you’ll get the error below to fix this please do the following: