Skip to content

Commit

Permalink
drm: move dereference below check
Browse files Browse the repository at this point in the history
"fb_helper_conn" is dereferenced before the check for NULL.  It's never
actually NULL here, so this is mostly to keep the static checkers happy.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Dan Carpenter authored and Dave Airlie committed Aug 19, 2010
1 parent 161c481 commit 09f0c48
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/gpu/drm/drm_fb_helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,11 @@ static bool drm_fb_helper_connector_parse_command_line(struct drm_fb_helper_conn
int i;
enum drm_connector_force force = DRM_FORCE_UNSPECIFIED;
struct drm_fb_helper_cmdline_mode *cmdline_mode;
struct drm_connector *connector = fb_helper_conn->connector;
struct drm_connector *connector;

if (!fb_helper_conn)
return false;
connector = fb_helper_conn->connector;

cmdline_mode = &fb_helper_conn->cmdline_mode;
if (!mode_option)
Expand Down

0 comments on commit 09f0c48

Please sign in to comment.