diff options
author | Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br> | 2008-11-24 15:15:43 -0200 |
---|---|---|
committer | Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br> | 2008-11-24 15:15:43 -0200 |
commit | 26ce0b163d9cf44ec1bc1d1bd460887aa5b405a7 (patch) | |
tree | 5063cb22f76ece5925f2bbfa6713f978715b770a /src/smilynx_output.c | |
parent | 2057d7ae05ef269f75a4d53fe5c4914a10856cb1 (diff) |
Use a single debug macro for leaving functions.
The LEAVE() macro, when debug is disabled, now is defined as:
<hash>define LEAVE(...) return __VA_ARGS__
This avoids the requirement of a return statement after the LEAVE()
macro call, what can be confusing.
Diffstat (limited to 'src/smilynx_output.c')
-rw-r--r-- | src/smilynx_output.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/smilynx_output.c b/src/smilynx_output.c index d55d808..40fe710 100644 --- a/src/smilynx_output.c +++ b/src/smilynx_output.c @@ -150,7 +150,7 @@ SMILynx_OutputGetModes_crt(xf86OutputPtr output) (pMon->rawData[6] == 0xFF) && (pMon->rawData[7] == 0x00)) { xf86OutputSetEDID(output,pMon); - RETURN(xf86OutputGetEDIDModes(output)); + LEAVE(xf86OutputGetEDIDModes(output)); } } @@ -158,7 +158,7 @@ SMILynx_OutputGetModes_crt(xf86OutputPtr output) pMon=SMILynx_ddc1(pScrn); if(pMon){ xf86OutputSetEDID(output,pMon); - RETURN(xf86OutputGetEDIDModes(output)); + LEAVE(xf86OutputGetEDIDModes(output)); } /* Try DDC2 */ @@ -166,12 +166,12 @@ SMILynx_OutputGetModes_crt(xf86OutputPtr output) pMon=xf86OutputGetEDID(output,pSmi->I2C); if(pMon){ xf86OutputSetEDID(output,pMon); - RETURN(xf86OutputGetEDIDModes(output)); + LEAVE(xf86OutputGetEDIDModes(output)); } } } - RETURN(NULL); + LEAVE(NULL); } static xf86OutputStatus @@ -202,9 +202,9 @@ SMILynx_OutputDetect_crt(xf86OutputPtr output) VGAOUT8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x7D, SR7D); if(status) - RETURN(XF86OutputStatusConnected); + LEAVE(XF86OutputStatusConnected); else - RETURN(XF86OutputStatusDisconnected); + LEAVE(XF86OutputStatusDisconnected); } static xf86OutputFuncsRec SMILynx_Output0Funcs; @@ -228,7 +228,7 @@ SMILynx_OutputPreInit(ScrnInfoPtr pScrn) output0=xf86OutputCreate(pScrn,&SMILynx_Output0Funcs,"LVDS"); if(!output0) - RETURN(FALSE); + LEAVE(FALSE); output0->possible_crtcs = 1 << 0; output0->possible_clones = 0; @@ -244,7 +244,7 @@ SMILynx_OutputPreInit(ScrnInfoPtr pScrn) output0=xf86OutputCreate(pScrn,&SMILynx_Output0Funcs,"LVDS"); if(!output0) - RETURN(FALSE); + LEAVE(FALSE); output0->possible_crtcs = 1 << 0; output0->possible_clones = 0; @@ -259,7 +259,7 @@ SMILynx_OutputPreInit(ScrnInfoPtr pScrn) output1=xf86OutputCreate(pScrn,&SMILynx_Output1Funcs,"VGA"); if(!output1) - RETURN(FALSE); + LEAVE(FALSE); output1->possible_crtcs = 1 << 1; output1->possible_clones = 0; @@ -274,7 +274,7 @@ SMILynx_OutputPreInit(ScrnInfoPtr pScrn) output0=xf86OutputCreate(pScrn,&SMILynx_Output0Funcs,"LVDS"); if(!output0) - RETURN(FALSE); + LEAVE(FALSE); output0->possible_crtcs = 1 << 0; output0->possible_clones = 0; @@ -283,6 +283,6 @@ SMILynx_OutputPreInit(ScrnInfoPtr pScrn) } } - RETURN(TRUE); + LEAVE(TRUE); } |