aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2010-08-02 09:00:24 +0000
committermarha <marha@users.sourceforge.net>2010-08-02 09:00:24 +0000
commit240baf59a219841c5f8942c82f7ed61da9d2323b (patch)
tree76937e127002c1ba58c5a379651f20a17e866627 /xorg-server/hw/xfree86
parent6c5a4ae0c8e57225ce31fb0a39c87ec9a5eed2b5 (diff)
parentd2758df0a0091496717fe7a65c3e7563e7c82785 (diff)
downloadvcxsrv-240baf59a219841c5f8942c82f7ed61da9d2323b.tar.gz
vcxsrv-240baf59a219841c5f8942c82f7ed61da9d2323b.tar.bz2
vcxsrv-240baf59a219841c5f8942c82f7ed61da9d2323b.zip
svn merge ^/branches/released .
Diffstat (limited to 'xorg-server/hw/xfree86')
-rw-r--r--xorg-server/hw/xfree86/ddc/ddc.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/xorg-server/hw/xfree86/ddc/ddc.c b/xorg-server/hw/xfree86/ddc/ddc.c
index 3b70ce508..975e07620 100644
--- a/xorg-server/hw/xfree86/ddc/ddc.c
+++ b/xorg-server/hw/xfree86/ddc/ddc.c
@@ -102,7 +102,7 @@ resort(unsigned char *s_block)
}
static int
-DDC_checksum(unsigned char *block, int len)
+DDC_checksum(const unsigned char *block, int len)
{
int i, result = 0;
int not_null = 0;
@@ -149,7 +149,10 @@ GetEDID_DDC1(unsigned int *s_ptr)
d_pos++;
}
free(s_ptr);
- if (d_block && DDC_checksum(d_block,EDID1_LEN)) return NULL;
+ if (d_block && DDC_checksum(d_block,EDID1_LEN)) {
+ free(d_block);
+ return NULL;
+ }
return (resort(d_block));
}