diff options
Diffstat (limited to 'examples/mac.c')
-rw-r--r-- | examples/mac.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/examples/mac.c b/examples/mac.c index 2d335a4..1c85d73 100644 --- a/examples/mac.c +++ b/examples/mac.c @@ -455,6 +455,8 @@ ScreenInit(int argc, char**argv) CGDisplayPixelsHigh(kCGDirectMainDisplay), bitsPerSample, CGDisplaySamplesPerPixel(kCGDirectMainDisplay),4); + if(!rfbScreen) + exit(0); rfbScreen->serverFormat.redShift = bitsPerSample*2; rfbScreen->serverFormat.greenShift = bitsPerSample*1; rfbScreen->serverFormat.blueShift = 0; |