Commit graph

1271 commits

Author SHA1 Message Date
Ross Burton
c827edcd1c Add missing NULL checks to ICWrap
ICWrap.c dereferences the xim parameter passed in from client code without a
NULL check.  I have seen mplayer trigger this resulting in a segfault.  In this
case mplayer had called XOpenIM and NULL was returned which was later passed
into XCreateIC.

Patch originally by Drew Moseley <drew_moseley@mentor.com>.

Signed-off-by: Ross Burton <ross.burton@intel.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-07-19 08:49:39 -07:00
Alan Coopersmith
26e0d2de29 Replace Xmalloc+memset pairs with Xcalloc calls
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-06-04 20:51:17 -07:00
Bhavi Dhingra
f0286b2770 omGeneric.c: Correct the parameter usage of sizeof
Incorrect parameter usage with sizeof. Earlier passed argument FontData
will be 4 bytes always as its a pointer hence the change is needed and
FontDataRec should be used for memset.

Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-06-04 19:08:31 -07:00
Peter Hutterer
47da70d75f Fix three "use of uninitialized variable" coverity warnings
False positive, if rlen/nbytes are unset we quit early before using it. Still,
initialize it so we don't have to deal with these warnings again.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-05-20 08:00:33 +10:00
Peter Hutterer
19a30f17f3 Fix an indentation issue
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-05-18 07:56:22 +10:00
Peter Hutterer
013ccece12 Fix potential memory leak
If we hit the depth limit, filename leaks. Move the depth check up before we
allocate filename.
Introduced in 226622349a.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-05-18 07:55:17 +10:00
Mike FABIAN
d3415d1f05
Fix spelling mistake introduced by 748d47e69f
Sorry, my patch to fix the spelling mistakes in the ks_IN and sd_IN
locales fixed it only partly, I introduced a new spelling mistake
in the sd_IN locales. This patch fixes this.

Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-04-20 15:55:42 -04:00
Mike FABIAN
748d47e69f
fix spelling mistakes in ks_IN and sd_IN devanagari locales
The codeset must be *before* the modifier.

See also: http://pubs.opengroup.org/onlinepubs/7908799/xbd/envvar.html

opengroup> The syntax for these environment variables is thus defined as:
opengroup>
opengroup> [language[_territory][.codeset][@modifier]]

Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-04-20 10:40:52 -04:00
Mike FABIAN
c64fe5553a
add be_BY.UTF-8@latin and sr_RS.UTF-8@latin to locale.dir
See also: https://bugzilla.redhat.com/show_bug.cgi?id=1066910

If these are not in locale.dir,

    $ LANG=sr_RS.UTF-8@latin xterm

and

    $ LANG=sr_RS@latin xterm

give the warning:

    Warning: locale not supported by Xlib, locale set to C

and some programs (like xmms) fail to find translations for Serbian
in Latin because of this.

Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-04-20 10:37:57 -04:00
Alan Coopersmith
c85be01b00 Move Compose \ o / to be with other emoji compose sequences
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-03-22 16:46:45 -07:00
Alan Coopersmith
5a499ca7b0 libX11 1.6.3
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2015-03-09 15:28:29 -07:00
Joonas Javanainen
c8e19b393d Fix XErrorEvent struct field order in man page
In the man page the field "resourceid" was in a different place than
in the actual struct layout in Xlib.h

Signed-off-by: Joonas Javanainen <joonas.javanainen@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-02-06 12:58:38 +10:00
Ran Benita
ddf3b09bb2 compose: fix the description of modifiers in compose sequences
The Compose format has a feature which allows specifying certain
modifiers must (or must not) be present with a given keysym in the
sequence.

The grammar in imLcPrs.c and the Compose man page both do not match what
the code actually does (see the handling of the variables
`modifier_mask` and `modifier` in parseline() in imLcPrs.c, which are
eventually matched as `ev->state & modifier_mask == modifier`).

Also explicitly list the accepted modifier names, since they are
not standard (e.g. "Ctrl" instead of "Control").

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-02-05 17:36:01 -05:00
Ran Benita
129f13f385 xkb: fix misleading comment about consumed modifiers
In the spec and the man page the `mods_rtrn` argument is described as
"backfilled with unconsumed modifiers" but actually it is backfilled
with the *consumed* modifiers. This is also mentioned a few lines below
in each case.

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-02-05 17:35:57 -05:00
Ingo Schwarze
446f5f7f41 Fix pasto in XkbGetKeyBehaviors(3) manual
Reviewed-by: Thomas Klausner <wiz@NetBSD.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2014-12-10 10:01:42 +10:00
Benno Schulenberg
f3831dde69
nls: Sorting compose sequences rigorously in mirroring pairs, as is custom.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
2014-11-23 17:53:13 -05:00
Benno Schulenberg
a51681b60c
nls: Remove a duplicate locale name, and sort some others more strictly.
Also improve the grammar of the initial comment.

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:21:56 -05:00
Benno Schulenberg
426b7f850f
nls: Add a comment to the block of accented Hebrew letters.
And align them in a nicer manner.

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:21:54 -05:00
Benno Schulenberg
7474c6f1ee
nls: Add one lowercase compose variant for ®, to mirror those for ©.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:21:41 -05:00
Benno Schulenberg
18dcd13514
nls: Adding the visual composing characters to two comment lines.
The lines around them also contain the characters in the comments.

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:21:30 -05:00
Benno Schulenberg
18d8307575
nls: Grouping a lone superscript minus together with its mates.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:21:15 -05:00
Benno Schulenberg
33301cc45e
nls: Grouping the compose sequences for Dstroke/dstroke together.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-10 09:20:51 -05:00
Gioele Barabucci
78fe1becb6
Add compose sequence for U+20B9 INDIAN RUPEE SIGN
The compose sequence for the new Indian Rupee sign is modelled after
the sequence for the Euro sign.

Signed-off-by: Gioele Barabucci <gioele@svario.it>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-11-09 10:29:45 -05:00
Gabriel Souza Franco
6101b967b6 Add double-arrow compose sequence
Signed-off-by: Gabriel Souza Franco <gabrielfrancosouza@gmail.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-08-26 15:40:26 -07:00
James Cloos
368a6401c6
Add cs_CZ.UTF-8 locale to configure.ac
Commit cf4d598938 should have included this.

Reported-by: Colin Harrison <colin.harrison@virgin.net>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-08-01 18:32:27 -04:00
James Cloos
cf4d598938 Add nls for cs_CZ.UTF-8
Based on the iso8859-2 compose, and a bug report by Vladimír Marek,
override the en_US.UTF-8 use of <dead_caron> <u> to enter »ǔ« instead
to enter »ů«, and likewise for the majuscule, for the Czech locale.

This evidently is the norm for Czech keyboards.

Fixes bz#81875.

The XI18N_OBJS and XLC_LOCALE.pre files are empty, as they are for
several other locales.  That may require an update.

Reported-by:  Vladimír Marek <vlmarek@volny.cz>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2014-07-29 15:11:41 -04:00
Alan Coopersmith
d9f569572b Fix source paths for out-of-tree lintlib builds
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-26 12:17:47 -07:00
Alan Coopersmith
0885cad1e4 specs/XKB: Markup fractions as <{super,sub}script> instead of <emphasis>
Matches the way they were styled in original doc, before conversion
to DocBook.

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-20 09:21:24 -07:00
Alan Coopersmith
d0a9e9d56b specs/XKB: acknowledge my contributions
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:55:47 -07:00
Alan Coopersmith
9c0be82017 specs/XKB: Trim leading spaces off text lines
perl -i -p -e 's{/\*(\S)}{/* \1}g;' *.xml

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:55:38 -07:00
Alan Coopersmith
75b0b10990 specs/XKB: Add olinks to libX11 for "X Library Functions Affected by Xkb"
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:51:06 -07:00
Alan Coopersmith
5009621799 specs/XKB: Fix miscelleanous typos & spelling errors
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:51:06 -07:00
Alan Coopersmith
ac219bf152 specs/XKB: add some more indexterms by hand
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:51:06 -07:00
Alan Coopersmith
5c3aa4c69e specs/XKB: fixup various formatting issues in <programlisting>s
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 23:51:05 -07:00
Alan Coopersmith
70c648ff85 specs/XKB: fixup various formatting issues in <literallayout>s
Including translating some that are really just lists into
<simplelist> markup.

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:44 -07:00
Alan Coopersmith
94b5677478 specs/XKB: add some more links by hand
random bits where a link looked handy

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:44 -07:00
Alan Coopersmith
7a15a934cd specs/XKB: add links for terms in definition list under figure 1.1
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:43 -07:00
Alan Coopersmith
92b86fc3c5 specs/XKB: add links to more tables listing section references
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:43 -07:00
Alan Coopersmith
06a4483a05 specs/XKB: Table 4.1: remove page numbers & unnecessary para tags
Page numbers refer to old doc format, didn't translate to new one

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:43 -07:00
Alan Coopersmith
61bd55c6d1 specs/XKB: remove unwanted white space around C -&gt; struct references
perl -i -0 -p -e 's{\s*-&gt;\s*}{-&gt;}g' *xml

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:19:42 -07:00
Alan Coopersmith
2be0cc0b2a specs/XKB: replace -&gt; with &rarr; when used as arrow, not in C structs
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:57 -07:00
Alan Coopersmith
bf1f3d6f6f specs/XKB: replace =&gt; with &rArr; for double arrows
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:56 -07:00
Alan Coopersmith
c7ee427fc0 specs/XKB: Markup some ranges with &ndash; instead of - 2014-07-19 20:18:56 -07:00
Alan Coopersmith
ec4075303c specs/XKB: Markup some subtractions with &minus; instead of -
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:56 -07:00
Alan Coopersmith
441a267e46 specs/XKB: make sure all files have DOCTYPEs so standard entities work
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:56 -07:00
Alan Coopersmith
88fd70bee4 specs/XKB: Markup quoted terms as <quote> instead of with ""
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:56 -07:00
Alan Coopersmith
3576587ff1 specs/XKB: fixup newlines between tags and punctuation
Get rid of unwanted whitespace before punctuation by moving them to the
lines with the tags, instead of before & after.

perl -i -0 -p -e 's{\>\s*\n([\.,;:])}{>\1\n}g' *xml

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:56 -07:00
Alan Coopersmith
6d5ec492cd specs/XKB: fixup newlines between tags and parens
Get rid of unwanted whitespace inside parens by moving them to the
lines with the tags, instead of before & after.

perl -i -0 -p \
     -e 's{(?<!--) \(\s*\n\<}{\n(<}g;' \
     -e 's{\>\s*\n\)([\.,;]?)(?! [^\n]*--)}{>)\1\n}g' *xml

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:54 -07:00
Alan Coopersmith
59d688f4c7 specs/XKB: Markup key terms as <firstterm> instead of <emphasis>
Also add <indexterm> entries for most of them, to make their definitions
or introductions easy to find from the index.

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:14 -07:00
Alan Coopersmith
861f3087ee specs/XKB: Manual fixup of type markup
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-07-19 20:18:14 -07:00