aboutsummaryrefslogtreecommitdiff
path: root/libdrm/xf86drm.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2002-11-25 16:03:20 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2002-11-25 16:03:20 +0000
commitc869f4a1e59c4fa0bed5681cad5ad49e685603eb (patch)
treed000e42bc29f36c1f86f04a2f5897e53785815a2 /libdrm/xf86drm.c
parenta654424ca16dca5d27e91592e2082d1381f6d5f5 (diff)
added missing return fd (Alexander Stohr)
Diffstat (limited to 'libdrm/xf86drm.c')
-rw-r--r--libdrm/xf86drm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libdrm/xf86drm.c b/libdrm/xf86drm.c
index 0532a1ec..6c830664 100644
--- a/libdrm/xf86drm.c
+++ b/libdrm/xf86drm.c
@@ -245,6 +245,7 @@ static int drmOpenDevice(long dev, int minor)
fd = open(buf, O_RDWR, 0);
drmMsg("drmOpenDevice: open result is %d, (%s)\n",
fd, fd < 0 ? strerror(errno) : "OK");
+ if (fd >= 0) return fd;
drmMsg("drmOpenDevice: Open failed\n");
remove(buf);