summaryrefslogtreecommitdiff
path: root/include/X11
AgeCommit message (Collapse)Author
2022-12-04ICEmsg: Fix C++ interoperability error due to static_assert defineArsen Arsenović
Commit 0269c687e954db7aca2a4344e32cb203315a00b6 added a static_assert helper that gets defined to blank if left undefined by assert.h. As this is not a macro in other languages that use this header, this can lead to a compile-time error. Bug: https://bugs.gentoo.org/884369
2022-11-02Avoid -Wdeclaration-after-statement warnings from static_assertAlan Coopersmith
Some implementations of static_assert() define a new variable. Avoid warnings from those when calling static_assert() from a macro that may not be at the top of a new code block. ../../src/accept.c: In function 'IceAcceptConnection': ../../src/accept.c:159:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement] 159 | IceGetHeader (iceConn, 0, ICE_ByteOrder, | ^~~~~~~~~~~~ ../../src/connect.c: In function 'IceOpenConnection': ../../src/connect.c:254:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement] 254 | IceGetHeader (iceConn, 0, ICE_ByteOrder, | ^~~~~~~~~~~~ ../../src/connect.c:340:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement] 340 | IceGetHeaderExtra (iceConn, 0, ICE_ConnectionSetup, | ^~~~~~~~~~~~~~~~~ [...etc...] Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-09-07ICEmsg.h: Add static asserts that message header length <= ICE_OUTBUFSIZEAlan Coopersmith
A message header length larger than ICE_OUTBUFSIZE will cause buffer overflows. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-09-07IceGetHeaderExtra: only include extra space in outbufptr if there's roomAlan Coopersmith
If there's not room for it in the buffer, we already set pData to NULL, but still set the outbufptr to include the space, which could lead to IceFlush() reading past the end of the buffer. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-30Fix spelling/wording issuesAlan Coopersmith
Found by using: codespell --builtin clear,rare,usage,informal,code,names Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2019-03-24IceWritePad: always use zero values for pad bytesAlan Coopersmith
Previously it would just bump the pointer in the buffer leaving whatever values were previously there in place. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2018-11-10Remove obsolete B16 & B32 tags in struct definitionsAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-08-08Cast assignments in IceErrorHeader() macroAlan Coopersmith
Clears many clang warnings about implicit conversions losing integer precision, such as from storing ints into CARD8 or CARD16. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-08-08Stop casting return values from mallocAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-08-08Get rid of casts to (char *) in calls to free()Alan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-07-20unifdef WORD64Alan Coopersmith
Remove leftover remnants of CRAY support, which still had some functions consisting solely of /* NOT IMPLEMENTED YET */ comments. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-07-20Constify filename argument to IceLockAuthFile & IceUnlockAuthFileAlan Coopersmith
Needed to fix const string warnings in iceauth - functions already copy provided arguments to temporary local buffer for modifications. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2011-11-22Constify protocol, vendor & release string args to IceRegisterForProtocol*Alan Coopersmith
Needed to resolve gcc -Wwrite-strings warnings in callers. These functions only pass the strings to strcmp before calling strdup to make their own private copy for storing away. While fixing the API docs to match, also fix them to match the existing function prototypes, where there were several errors before (including just plain missing most of the args to IceRegisterForProtocolReply). Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-11-11constify arguments to IceGetAuthFileEntryAlan Coopersmith
Needed to clear gcc -Wwrite-strings warnings in callers Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-09-16Strip trailing whitespaceAlan Coopersmith
Performed with: find * -type f | xargs perl -i -p -e 's{[ \t]+$}{}' git diff -w & git diff -b show no diffs from this change Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2011-04-21IceWritePad: Zero fill pad bytes used when buffer is fullAlan Coopersmith
Should be rarely hit, since it's only in the case where most of the message fits in the buffer, but there's not room left for the padding bytes, but better than sending uninitialized bytes off the stack when it happens. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-10-06Purge cvs tags.Jesse Adkins
Signed-off-by: Jesse Adkins <jesserayadkins@gmail.com> Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2009-01-06towards ANSI CPeter Breitenlohner
make _IceProcessCoreMessage and default error handlers static
2008-10-07Constify some arguments in libICE to clear warnings in libSMPeter Breitenlohner
This patch avoids the gcc (3.4.6) warnings: ../../libSM-1.0.3/src/sm_client.c:104: warning: passing arg 7 of `IceRegisterForProtocolSetup' from incompatible pointer type ../../libSM-1.0.3/src/sm_manager.c:168: warning: passing arg 7 of `IceRegisterForProtocolReply' from incompatible pointer type when compiling libSM
2005-06-10Remove pointless include of Xlib.h.XORG-6_8_99_13XORG-6_8_99_12XORG-6_8_99_11Daniel Stone
Fix #include path to bigreqstr.h.
2005-01-28Move _IceGetPeerName into the ICE public API as IceGetPeerName; bump ICEsco_port_update-baseXORG-6_8_99_7XORG-6_8_99_6XORG-6_8_99_5XORG-6_8_99_4XORG-6_8_99_3XORG-6_8_99_2XORG-6_8_99_1sco_port_updateDaniel Stone
soversion to 6.4 accordingly. Change SM's use to the public version. The old version will be retained for compatibility.
2004-04-23Merging XORG-CURRENT into trunkxprint_packagertest_20041217_basexprint_packagertest_20041125_baserel-0-6-1lg3d-rel-0-7-0lg3d-rel-0-6-2lg3d-baseXORG-6_8_2XORG-6_8_1_904XORG-6_8_1_903XORG-6_8_1_902XORG-6_8_1_901XORG-6_8_1XORG-6_8_0XORG-6_7_99_904XORG-6_7_99_903XORG-6_7_99_902XORG-6_7_99_901XORG-6_7_99_2XORG-6_7_99_1XACE-SELINUX-MERGExprint_packagertest_20041217xprint_packagertest_20041125lg3d-masterlg3d-eventlg3d-dev-0-7-1lg3d-dev-0-7-0lg3d-dev-0-6-latestlg3d-dev-0-6-2lg3d-dev-0-6-1-latestlg3d-dev-0-6-1-currentlg3d-dev-0-6-1-1lg3d-dev-0-6-1lg3dXORG-6_8-branchCOMPOSITEWRAPEgbert Eich
2004-03-14Importing vendor version xf86-4_4_99_1 on Sun Mar 14 00:26:39 PST 2004xf86-4_4_99_1Egbert Eich
2004-03-03Importing vendor version xf86-4_4_0 on Wed Mar 3 04:09:24 PST 2004xf86-4_4_0STSF-CURRENTEgbert Eich
2004-02-26readding XFree86's cvs IDsxf86-4_3_99_903Egbert Eich
2004-02-26Importing vendor version xf86-4_3_99_903 on Wed Feb 26 01:21:00 PST 2004Egbert Eich
2003-11-25XFree86 4.3.99.16 Bring the tree up to date for the Cygwin folksxf86-4_3_99_16Kaleb Keithley
2003-11-14XFree86 4.3.0.1xf86-4_3_0_1PRE_xf86-4_3_0_1Kaleb Keithley
2003-11-14R6.6 is the Xorg base-lineXORG-MAINXORG-STABLEKaleb Keithley