This commit is contained in:
parent
190e473e27
commit
44ac73bc40
@ -5,103 +5,167 @@
|
||||
unsigned long argument, data1 = 0, data2 = 0;
|
||||
|
||||
- if (action == NULL || action == "\0")
|
||||
+ if (action == NULL || (strcmp(action,"\0") == 0))
|
||||
+ if (action == NULL || action[0] == '\0')
|
||||
{
|
||||
return;
|
||||
}
|
||||
--- libs/Flocale.c
|
||||
+++ libs/Flocale.c
|
||||
@@ -1080,7 +1080,7 @@
|
||||
@@ -1066,21 +1066,22 @@
|
||||
FftFontType *fftf = NULL;
|
||||
FlocaleFont *flf = NULL;
|
||||
char *fn, *hints = NULL;
|
||||
+ char *fallback_font = FLOCALE_FFT_FALLBACK_FONT;
|
||||
|
||||
hints = GetQuotedString(fontname, &fn, "/", NULL, NULL, NULL);
|
||||
if (fn == NULL)
|
||||
{
|
||||
- fn = FLOCALE_FFT_FALLBACK_FONT;
|
||||
+ fn = fallback_font;
|
||||
}
|
||||
else if (*fn == '\0')
|
||||
{
|
||||
free(fn);
|
||||
- fn = FLOCALE_FFT_FALLBACK_FONT;
|
||||
+ fn = fallback_font;
|
||||
}
|
||||
fftf = FftGetFont(dpy, fn, module);
|
||||
if (fftf == NULL)
|
||||
{
|
||||
- if (fn != NULL && fn != FLOCALE_FFT_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *)FLOCALE_FFT_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1095,7 +1095,7 @@
|
||||
@@ -1095,7 +1096,7 @@
|
||||
&flf->fftf, &flf->height, &flf->ascent, &flf->descent);
|
||||
FftGetFontWidths(flf, &flf->max_char_width);
|
||||
free(fftf);
|
||||
- if (fn != NULL && fn != FLOCALE_FFT_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_FFT_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1124,7 +1124,7 @@
|
||||
@@ -1115,16 +1116,17 @@
|
||||
char *ds;
|
||||
XFontSetExtents *fset_extents;
|
||||
char *fn, *hints = NULL, *fn_fixed = NULL;
|
||||
+ char *fallback_font = FLOCALE_MB_FALLBACK_FONT;
|
||||
|
||||
hints = GetQuotedString(fontname, &fn, "/", NULL, NULL, NULL);
|
||||
if (*fn == '\0')
|
||||
{
|
||||
free(fn);
|
||||
- fn = fn_fixed = FLOCALE_MB_FALLBACK_FONT;
|
||||
+ fn = fn_fixed = fallback_font;
|
||||
}
|
||||
else if (!(fn_fixed = FlocaleFixNameForFontSet(dpy, fn, module)))
|
||||
{
|
||||
- if (fn != NULL && fn != FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1136,7 +1136,7 @@
|
||||
@@ -1136,7 +1138,7 @@
|
||||
{
|
||||
free(fn_fixed);
|
||||
}
|
||||
- if (fn != NULL && fn != FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1185,7 +1185,7 @@
|
||||
@@ -1185,7 +1187,7 @@
|
||||
{
|
||||
free(fn_fixed);
|
||||
}
|
||||
- if (fn != NULL && fn != FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_MB_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1212,7 +1212,7 @@
|
||||
fn = FLOCALE_FALLBACK_FONT;
|
||||
@@ -1201,6 +1203,7 @@
|
||||
FlocaleFont *flf;
|
||||
char *str,*fn,*tmp;
|
||||
char *hints = NULL;
|
||||
+ char *fallback_font = FLOCALE_FALLBACK_FONT;
|
||||
|
||||
hints = GetQuotedString(fontname, &tmp, "/", NULL, NULL, NULL);
|
||||
str = GetQuotedString(tmp, &fn, ",", NULL, NULL, NULL);
|
||||
@@ -1209,10 +1212,10 @@
|
||||
if (*fn == '\0')
|
||||
{
|
||||
free(fn);
|
||||
- fn = FLOCALE_FALLBACK_FONT;
|
||||
+ fn = fallback_font;
|
||||
}
|
||||
font = XLoadQueryFont(dpy, fn);
|
||||
- if (fn != NULL && fn != FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
fn = NULL;
|
||||
@@ -1224,7 +1224,7 @@
|
||||
@@ -1224,7 +1227,7 @@
|
||||
}
|
||||
if (font == NULL)
|
||||
{
|
||||
- if (fn != NULL && fn != FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1248,7 +1248,7 @@
|
||||
@@ -1248,7 +1251,7 @@
|
||||
flf->max_char_width = font->max_bounds.width;
|
||||
if (flf->font->max_byte1 > 0)
|
||||
flf->flags.is_mb = True;
|
||||
- if (fn != NULL && fn != FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
@@ -1460,8 +1460,8 @@
|
||||
@@ -1382,6 +1385,8 @@
|
||||
int shadow_offset = 0;
|
||||
int shadow_dir = MULTI_DIR_SE;
|
||||
int i;
|
||||
+ char *mb_fallback_font = FLOCALE_MB_FALLBACK_FONT;
|
||||
+ char *fallback_font = FLOCALE_FALLBACK_FONT;
|
||||
|
||||
/* removing quoting for modules */
|
||||
if (fontname && (t = strchr("\"'`", *fontname)))
|
||||
@@ -1395,7 +1400,7 @@
|
||||
if (fontname == NULL || *fontname == 0)
|
||||
{
|
||||
ask_default = True;
|
||||
- fontname = FLOCALE_MB_FALLBACK_FONT;
|
||||
+ fontname = mb_fallback_font;
|
||||
}
|
||||
|
||||
while (flf)
|
||||
@@ -1454,14 +1459,14 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
- fn = FLOCALE_MB_FALLBACK_FONT;
|
||||
+ fn = mb_fallback_font;
|
||||
}
|
||||
while (!flf && (fn && *fn))
|
||||
{
|
||||
flf = FlocaleGetFontOrFontSet(
|
||||
dpy, fn, encoding, fontname, module);
|
||||
- if (fn != NULL && fn != FLOCALE_MB_FALLBACK_FONT &&
|
||||
- fn != FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_MB_FALLBACK_FONT &&
|
||||
+ fn != (char *) FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != mb_fallback_font &&
|
||||
+ fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
fn = NULL;
|
||||
@@ -1471,8 +1471,8 @@
|
||||
@@ -1471,8 +1476,7 @@
|
||||
str = GetQuotedString(str, &fn, ";", NULL, NULL, NULL);
|
||||
}
|
||||
}
|
||||
- if (fn != NULL && fn != FLOCALE_MB_FALLBACK_FONT &&
|
||||
- fn != FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != (char *) FLOCALE_MB_FALLBACK_FONT &&
|
||||
+ fn != (char *) FLOCALE_FALLBACK_FONT)
|
||||
+ if (fn != NULL && fn != mb_fallback_font && fn != fallback_font)
|
||||
{
|
||||
free(fn);
|
||||
}
|
||||
|
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 4 21:17:21 CEST 2007 - schwab@suse.de
|
||||
|
||||
- Fix last change.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 4 16:48:44 CEST 2007 - lmichnovic@suse.cz
|
||||
|
||||
|
@ -18,7 +18,7 @@ Provides: fvwmicns windowmanager xpmroot
|
||||
Obsoletes: fvwm xpmroot
|
||||
Autoreqprov: on
|
||||
Version: 2.5.21
|
||||
Release: 11
|
||||
Release: 12
|
||||
Summary: Improved Version of FVWM Window Manager
|
||||
URL: http://www.fvwm.org
|
||||
Source0: fvwm-2.5.21.tar.bz2
|
||||
@ -166,6 +166,8 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Wed Apr 04 2007 - schwab@suse.de
|
||||
- Fix last change.
|
||||
* Wed Apr 04 2007 - lmichnovic@suse.cz
|
||||
- fixed gcc warnings: comparing a char* pointer with a
|
||||
string literal (string_compar.patch)
|
||||
|
Loading…
Reference in New Issue
Block a user