aboutsummaryrefslogtreecommitdiff
path: root/linux-core/drm_proc.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2008-05-12 16:28:40 +1000
committerDave Airlie <airlied@redhat.com>2008-05-12 16:28:40 +1000
commit8f7fc880e8bbe9e59521df707f2ddd3e80e06e6f (patch)
treeafb6d1ea7799b0d560c5fe7bd271d0d2b93fceeb /linux-core/drm_proc.c
parentdce34421947d1828ff76c001281107e937e307d4 (diff)
drm: fix oops on reading proc file with no master
Diffstat (limited to 'linux-core/drm_proc.c')
-rw-r--r--linux-core/drm_proc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/linux-core/drm_proc.c b/linux-core/drm_proc.c
index b6748b9b..7f185209 100644
--- a/linux-core/drm_proc.c
+++ b/linux-core/drm_proc.c
@@ -175,6 +175,9 @@ static int drm_name_info(char *buf, char **start, off_t offset, int request,
return 0;
}
+ if (!master)
+ return 0;
+
*start = &buf[offset];
*eof = 0;