Age | Commit message (Collapse) | Author |
|
remove redundant null check on calling free()
Signed-off-by: Walter Harms <wharms@bfs.de>
Reviewed-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
|
|
If the environment variable HOME is empty, XauFileName triggers an
out of boundary read access (name[1]). If HOME consists of a single
character relative path, the output becomes unexpected, because
"HOME=a" leads to "a.Xauthority" instead of "a/.Xauthority". Granted,
a relative HOME path leads to trouble in general, the code should
properly return "a/.Xauthority" nonetheless.
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
AuFileName.c:72:8: warning: Call to 'malloc' has an allocation size of 0 bytes
buf = malloc (size);
^~~~~~~~~~~~~
Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
https://bugs.freedesktop.org/show_bug.cgi?id=69929
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
fread & fwrite are defined as taking size_t arguments (an unsigned type),
so stop casting their arguments to a signed int just to confuse things.
Fixes warnings:
AuFileName.c:69:59: warning: implicit conversion loses integer precision: 'unsigned long' to 'int' [-Wshorten-64-to-32]
size = strlen (name) + strlen(&slashDotXauthority[1]) + 2;
~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
AuRead.c:58:44: warning: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Wsign-conversion]
if (fread (data, (int) sizeof (char), (int) len, file) != len) {
~~~~~ ^~~~~~~~~
AuWrite.c:49:46: warning: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Wsign-conversion]
if (fwrite (string, (int) sizeof (char), (int) count, file) != count)
~~~~~~ ^~~~~~~~~~~
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
XauFileName() may allocate and return a static buffer. The only
way to ensure it is freed is to deallocate it when the program exits.
Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Signed-off-by: Jesse Adkins <jesserayadkins@gmail.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
but never used or defined
Fix sparse warnings:
-warning: Using plain integer as NULL pointer
-warning: non-ANSI definition of function
|
|
- Update AUTHORS, COPYING from Keith's tree
- Don't use gcc specific "-include config.h"
- Add autogen.sh
lib/xtrans:
- Add AUTHORS, COPYING, ChangeLog, Makefile.am, NEWS, README, autogen.sh,
configure.ac, xtrans.pc.in
xc/lib/Xau:
- Add conditionalized #include <config.h>
util/modular/symlink.sh
- Add functions symlink_lib_xau() and symlink_lib_xtrans()
util/modular/addconfig.h
- New script that adds #include <config.h> to files
|
|
mingw (Win32) port
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|