summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-03-02libXcursor 1.2.2HEADlibXcursor-1.2.2masterAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2024-01-18Remove superfluous and unguarded config.h includeRobin Linden
config.h is correctly included behind a HAVE_CONFIG_H guard earlier in the file, so this isn't needed. Signed-off-by: Robin Linden <dev@robinlinden.eu>
2023-10-08XcursorXcFileLoad: plug memory leak in error pathsAlan Coopersmith
Found by gcc analyzer: file.c: In function ‘XcursorXcFileLoad’: file.c:782:8: warning: leak of ‘fileHeader’ [CWE-401] [-Wanalyzer-malloc-leak] 782 | if (!images) | ^ Fixes: 3b84b14 ("Initial revision") Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-07-08Add comment about keeping libxcb-cursor copy of code in syncAlan Coopersmith
_XcursorThemeInherits, XcursorWhite, & XcursorSep are copied in libxcb-cursor/cursor/load_cursor.c and should be kept in sync with changes to the libXcursor originals of those. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-03-25If O_CLOEXEC is defined, add "e" to fopen modesAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-03-04configure: Use LT_INIT from libtool 2 instead of deprecated AC_PROG_LIBTOOLAlan Coopersmith
AC_PROG_LIBTOOL was replaced by LT_INIT in libtool 2 in 2008, so it's time to rely on it. Clears autoconf warnings: configure.ac:42: warning: The macro `AC_PROG_LIBTOOL' is obsolete. configure.ac:42: You should run autoupdate. aclocal.m4:3465: AC_PROG_LIBTOOL is expanded from... configure.ac:42: the top level libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac, libtoolize: and rerunning libtoolize and aclocal. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-02-09gitlab CI: stop requiring Signed-off-by in commitsAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-03libXcursor 1.2.1libXcursor-1.2.1Alan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-03gitlab CI: add a basic build testAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-03Build xz tarballs instead of bzip2Alan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-03Fix spelling/wording issuesAlan Coopersmith
Found by using: codespell --builtin clear,rare,usage,informal,code,names Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-03Convert COPYING from ISO-8859-1 to UTF-8Alan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2021-05-06more cppcheck-style fixesThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-05-05cppcheck style-fixesThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-05-05mention "Inherits=" listsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-05-04fix XcursorTheme loop regressionTobias Stoeckmann
Handle themes with multiple inherit entries. Although the previous commit keeped track of inherited themes, it only handled multiple theme entries on the highest level. This fix unconditionally checks if the next upper level contains a line. If it does, it processes contained themes (i.e. the current theme had an inherited entry in its index file). If the upper level has no more themes, it goes down a level and processes the next theme there. If no next theme exists, it moves down another level and so on until it reaches level 0, i.e. the initially supplied theme. The lowest level (d = 0) is treated specially because we must not modify the supplied theme, which could happen when calling _XcursorNextPath. Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2021-05-02Handle more theme loop situationsTobias Stoeckmann
This is a follow up for commit f64a8cc1a65dcad4294e2988b402a34175019663 resulting from https://bugs.freedesktop.org/show_bug.cgi?id=3603 The current loop detection only works for direct self references but not for transitive ones. Limiting the inheritance depth fixes this issue as suggested by Keith Packard. I avoided the introduction of a recursion function. Instead I modified XcursorScanTheme to work iterative. The current recursion code adds the "Inherits=..." line to heap and has an iteration variable to go through all themes listed in that line per recursion. This is covered with the newly introduced XcursorInherit struct with its fields "line" and "theme". Since "theme" points into "line", only "line" has to be freed eventually. If a fixed inheritage limit of 32 is reached, the code stops processing and returns NULL. It also returns NULL if it detects the initial theme in one of the inheritages to break the loop early on. Last but not least I removed the printf statement. The only situation in which libXcursor writes to stdout is when it is explicitly requested. Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2021-03-19eliminate special escaping for "/*" which produces look-alike Unicode forThomas E. Dickey
newer groff (making select/paste useless), but is not necessary with groff, mandoc or Solaris 10 nroff. Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-19fix a typo and a style issueThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17update copyright noticeThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17fix raggedy prototypes and structure declarations using tabstops in ↵Thomas E. Dickey
appropriate macros Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the API called from libX11Thomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the cursor-comments functionsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the animation support functionsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17improve explanation of Xcursor's search algorithmThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17start on the animated cursors; fixup whitespaceThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17update ".so" links, and fix a special case for "const char *" in parsing ↵Thomas E. Dickey
function-names Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the cursor-load functionsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17add see-also sectionThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the library-attributesThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the theme_core setter/getter functionsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17improve explanation for functions which load imagesThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17italicize parameter names, for readabilityThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17correct a prototypeThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17further formatting fixes. added script to create/find ".so" files which are ↵Thomas E. Dickey
missing Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17make the function-prototypes easier to read, by eliminating hyphenation and ↵Thomas E. Dickey
filling Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-17document the other environment variablesThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11amend that...Thomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11add check in case the image size is 0x0Thomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11fix stricter gcc warnings using castsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11fix stricter gcc warnings using castsThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11fix stricter gcc warnings by changing the type for the loop variable toThomas E. Dickey
match the type of the loop limit Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11quiet warnings for unused parametersThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11fix a missing initializerThomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2021-03-11quiet normal gcc warnings using casts (no object change)Thomas E. Dickey
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2020-08-30Fix undefined behaviorValentin
Without the casts the bytes accesses get converted to int. but int is not guaranteed to be 4 bytes large. Even when it is 4 bytes large `bytes[3] << 24` does not fit because int is signed.
2020-08-30Use fixed size integer typeValentin
This type is meant to be 4 bytes large as seen in _XcursorReadUInt which always reads 4 bytes. An unsigned int is often 4 bytes large but this isnt' guaranteed so it is cleaner to use the exact type we want.
2019-03-10libXcursor 1.2.0libXcursor-1.2.0Alan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2018-12-07Update configure.ac bug URL for gitlab migrationAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2018-11-19Update README for gitlab migrationAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>