diff options
author | Alexander Larsson <alexl@redhat.com> | 2013-04-03 15:49:54 +0200 |
---|---|---|
committer | Alexander Larsson <alexl@redhat.com> | 2013-04-03 15:58:41 +0200 |
commit | c340dfeaf84685f655f6e5ea2ff02b9b48763c78 (patch) | |
tree | b70af551a0863b08438dc6d199565935c926b18f /gdk | |
parent | b7a1561fef74144162613eb36978e5b7cb67a545 (diff) | |
download | gtk+-c340dfeaf84685f655f6e5ea2ff02b9b48763c78.tar.gz |
Broadway: Fix shm names
We were sometimes getting zero chars in the name, making them
shorter, due to an off-by-zero in the size.
Diffstat (limited to 'gdk')
-rw-r--r-- | gdk/broadway/gdkbroadway-server.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdk/broadway/gdkbroadway-server.c b/gdk/broadway/gdkbroadway-server.c index cb9bdf4664..adc28a0b72 100644 --- a/gdk/broadway/gdkbroadway-server.c +++ b/gdk/broadway/gdkbroadway-server.c @@ -506,7 +506,7 @@ make_valid_fs_char (char c) { char chars[] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890"; - return chars[c % sizeof (chars)]; + return chars[c % (sizeof (chars) - 1)]; } /* name must have at least space for 34 bytes */ |