Fixes gcc 5.3 compiler warning:
s3_bios.c: In function 'find_bios_string':
s3_bios.c:49:2: warning: suggest parentheses around assignment used as
truth value [-Wparentheses]
if (bios = NULL)
^
[Tested by compiling only, as I have no S3 hardware, but clearly no one
else has tested this code since commit c41a1188ce53 in 2009, as it would
be segfaulting if run.]
Signed-off-by: Alan Coopersmith <[email protected]>
---
src/s3_bios.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/s3_bios.c b/src/s3_bios.c
index 323e2ce..1c7c5fe 100644
--- a/src/s3_bios.c
+++ b/src/s3_bios.c
@@ -46,7 +46,7 @@ static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int
BIOSbase,
S3Ptr pS3 = S3PTR(pScrn);
bios = malloc(BIOS_BSIZE);
- if (bios = NULL)
+ if (bios == NULL)
return NULL;
if (!init) {
--
2.6.1
_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel