Quantcast
Channel: YouTrackReSharper (RSRP) - Bug and Issue Tracker
Viewing all articles
Browse latest Browse all 106942

RSRP-287139: ASP.NET MVC Controller: Using RedirectToAction still shows Possible 'System.NullReferenceException'

$
0
0
Reporter Mikael Koskinen (miksu) Mikael Koskinen (miksu)
Created Dec 20, 2011 3:08:31 PM
Updated Dec 27, 2011 4:52:40 PM
Resolved Dec 27, 2011 4:46:51 PM
Priority Normal
Type Bug
Fix versions No Fix versions
State Won't fix
Assignee Evgeny Pasynkov (pasynkov)
Subsystem Code Analysis - Find Code Issues
Affected versions 6.1
Fixed in build No Fixed in build
I have the following code:

            if (result == null)
                RedirectToAction("Index", "Report");

            if (result.ReportFile1 == null)
                RedirectToAction("Index", "Report");


ReSharper underlines the second if with a warning "Possible 'System.NullReferenceException'" even though the first RedirectToAction has already returned from the method.


Build 6.1.25.135 on 2011-12-07T23:28:36

Viewing all articles
Browse latest Browse all 106942

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>