diff --git a/legacy/ecore/AUTHORS b/legacy/ecore/AUTHORS index ebe354c817..3db7a4b24f 100644 --- a/legacy/ecore/AUTHORS +++ b/legacy/ecore/AUTHORS @@ -51,3 +51,4 @@ Bluezery Doyoun Kang Haifeng Deng Jérémy Zurcher +Vikram Narayanan diff --git a/legacy/ecore/src/lib/ecore_fb/ecore_fb.c b/legacy/ecore/src/lib/ecore_fb/ecore_fb.c index ca7d73d094..daeea0f8d9 100644 --- a/legacy/ecore/src/lib/ecore_fb/ecore_fb.c +++ b/legacy/ecore/src/lib/ecore_fb/ecore_fb.c @@ -92,21 +92,18 @@ _ecore_fb_size_get(int *w, int *h) fb = open("/dev/fb0", O_RDWR); if (fb < 0) - { - if (w) *w = 0; - if (h) *h = 0; - return; - } + goto exit; + if (ioctl(fb, FBIOGET_VSCREENINFO, &fb_var) == -1) - { - if (w) *w = 0; - if (h) *h = 0; - close(fb); - return; - } + goto err_ioctl; + + *w = fb_var.xres; + *h = fb_var.yres; + +err_ioctl: close(fb); - if (w) *w = fb_var.xres; - if (h) *h = fb_var.yres; +exit: + return; } /**