[svn] r5367 - trunk/rpms/xine
packagers at lists.rpmforge.net
packagers at lists.rpmforge.net
Fri May 4 17:33:30 CEST 2007
Author: thias
Date: 2007-05-04 17:33:27 +0200 (Fri, 04 May 2007)
New Revision: 5367
Removed:
trunk/rpms/xine/xine-ui-0.99.3-sprintf.patch
trunk/rpms/xine/xine-ui-0.99.3-uifixups.patch
trunk/rpms/xine/xine-ui-0.99.3-xftfontsize.patch
Modified:
trunk/rpms/xine/xine.spec
Log:
Update xine to 0.99.5 + minor improvements.
Deleted: trunk/rpms/xine/xine-ui-0.99.3-sprintf.patch
===================================================================
--- trunk/rpms/xine/xine-ui-0.99.3-sprintf.patch 2007-05-04 11:33:12 UTC (rev 5366)
+++ trunk/rpms/xine/xine-ui-0.99.3-sprintf.patch 2007-05-04 15:33:27 UTC (rev 5367)
@@ -1,1116 +0,0 @@
-diff -ur xine-ui-0.99.3/src/common/utils.c xine-ui-0.99.3.sprintf/src/common/utils.c
---- xine-ui-0.99.3/src/common/utils.c 2004-04-15 13:55:36.000000000 -0700
-+++ xine-ui-0.99.3.sprintf/src/common/utils.c 2005-07-07 02:18:25.546943500 -0700
-@@ -195,7 +195,7 @@
- pp = buf;
- while((p = xine_strsep(&pp, "/")) != NULL) {
- if(p && strlen(p)) {
-- sprintf(buf2, "%s/%s", buf2, p);
-+ sprintf(buf2+strlen(buf2), "/%s", p);
- if(!_mkdir_safe(buf2))
- return 0;
- }
-diff -ur xine-ui-0.99.3/src/fb/osd.c xine-ui-0.99.3.sprintf/src/fb/osd.c
---- xine-ui-0.99.3/src/fb/osd.c 2003-12-01 09:23:27.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/fb/osd.c 2005-07-05 18:53:05.000000000 -0700
-@@ -392,34 +392,34 @@
- len = strlen(buffer);
- switch(audiochannel) {
- case -2:
-- sprintf(buffer, "%soff", buffer);
-+ strcat(buffer, "off");
- break;
- case -1:
- if(!xine_get_audio_lang (fbxine.stream, audiochannel, &buffer[len]))
-- sprintf(buffer, "%sauto", buffer);
-+ strcat(buffer, "auto");
- break;
- default:
- if(!xine_get_audio_lang (fbxine.stream, audiochannel, &buffer[len]))
-- sprintf(buffer, "%s%3d", buffer, audiochannel);
-+ sprintf(&buffer[len], "%3d", audiochannel);
- break;
- }
-
-- sprintf(buffer, "%s, Spu: ", buffer);
-+ strcat(buffer, ", Spu: ");
- len = strlen(buffer);
- switch (spuchannel) {
- case -2:
-- sprintf(buffer, "%soff", buffer);
-+ strcat(buffer, "off");
- break;
- case -1:
- if(!xine_get_spu_lang (fbxine.stream, spuchannel, &buffer[len]))
-- sprintf(buffer, "%sauto", buffer);
-+ strcat(buffer, "auto");
- break;
- default:
- if(!xine_get_spu_lang (fbxine.stream, spuchannel, &buffer[len]))
-- sprintf(buffer, "%s%3d", buffer, spuchannel);
-+ sprintf(&buffer[len], "%3d", spuchannel);
- break;
- }
-- sprintf(buffer, "%s.", buffer);
-+ strcat(buffer, ".");
- xine_osd_draw_text(fbxine.osd.sinfo, x, y, buffer, XINE_OSD_TEXT1);
- xine_osd_get_text_size(fbxine.osd.sinfo, buffer, &w, &h);
- if(w > osdw)
-diff -ur xine-ui-0.99.3/src/xitk/file_browser.c xine-ui-0.99.3.sprintf/src/xitk/file_browser.c
---- xine-ui-0.99.3/src/xitk/file_browser.c 2004-12-12 06:19:08.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/file_browser.c 2005-07-05 19:01:50.000000000 -0700
-@@ -983,7 +983,7 @@
- snprintf(buf, sizeof(buf), "%s", fb->current_dir);
- if(strlen(fb->current_dir) > 1)
- strcat(buf, "/");
-- sprintf(buf, "%s%s", buf, fb->norm_files[sel].name);
-+ strcat(buf, fb->norm_files[sel].name);
-
- if((unlink(buf)) == -1)
- xine_error(_("Unable to delete file '%s': %s."), buf, strerror(errno));
-@@ -1006,7 +1006,7 @@
- snprintf(buf, sizeof(buf), _("Do you really want to delete the file: '%s'"), fb->current_dir);
- if(strlen(fb->current_dir) > 1)
- strcat(buf, "/");
-- sprintf(buf, "%s%s' ?.", buf, fb->norm_files[sel].name);
-+ sprintf(buf+strlen(buf), "%s' ?", fb->norm_files[sel].name);
-
- fb_deactivate(fb);
- xitk_window_dialog_yesno(gGui->imlib_data, _("Confirm deletion ?"),
-@@ -1025,7 +1025,7 @@
- snprintf(buf, sizeof(buf), "%s", fb->current_dir);
- if(strlen(fb->current_dir) > 1)
- strcat(buf, "/");
-- sprintf(buf, "%s%s", buf, fb->norm_files[sel].name);
-+ strcat(buf, fb->norm_files[sel].name);
-
- if((rename(buf, newname)) == -1)
- xine_error(_("Unable to rename file '%s' to '%s': %s."), buf, newname, strerror(errno));
-@@ -1044,7 +1044,7 @@
- snprintf(buf, sizeof(buf), "%s", fb->current_dir);
- if(strlen(fb->current_dir) > 1)
- strcat(buf, "/");
-- sprintf(buf, "%s%s", buf, fb->norm_files[sel].name);
-+ strcat(buf, fb->norm_files[sel].name);
-
- fb_deactivate(fb);
- fb_create_input_window(_("Rename file"), buf, fb_rename_file_cb, fb);
-diff -ur xine-ui-0.99.3/src/xitk/kbindings.c xine-ui-0.99.3.sprintf/src/xitk/kbindings.c
---- xine-ui-0.99.3/src/xitk/kbindings.c 2004-12-16 08:14:08.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/kbindings.c 2005-07-07 01:53:29.110252000 -0700
-@@ -590,12 +590,12 @@
- char *header = _("The following key bindings pairs are identical:\n\n");
- len += strlen(header);
- kmsg = (char *) xine_xmalloc(len + 1);
-- sprintf(kmsg, "%s%s%c%s%c%s", header, action1,' ', dna, ' ', action2);
-+ sprintf(kmsg, "%s%s %s %s", header, action1, dna, action2);
- }
- else {
- len += 2;
- kmsg = (char *) realloc(kmsg, strlen(kmsg) + len + 1);
-- sprintf(kmsg, "%s%s%s%c%s%c%s", kmsg, ", ", action1, ' ', dna, ' ', action2);
-+ sprintf(kmsg+strlen(kmsg), ", %s %s %s", action1, dna, action2);
- }
- }
- }
-@@ -607,7 +607,7 @@
- char *footer = _(".\n\nWhat do you want to do ?\n");
-
- kmsg = (char *) realloc(kmsg, strlen(kmsg) + strlen(footer) + 1);
-- sprintf(kmsg, "%s%s", kmsg, footer);
-+ strcat(kmsg, footer);
-
- dump_error(gGui->verbosity, kmsg);
-
-@@ -1007,16 +1007,14 @@
-
- for(k = kbt->entry, i = 0; k[i]->action != NULL; i++) {
- if(!k[i]->is_alias) {
-- sprintf(buf, "# %s\n", k[i]->comment);
-- sprintf(buf, "%sbegin\n", buf);
-- sprintf(buf, "%s\tremote = xxxxx\n", buf);
-- sprintf(buf, "%s\tbutton = xxxxx\n", buf);
-- sprintf(buf, "%s\tprog = xine\n", buf);
-- sprintf(buf, "%s\trepeat = 0\n", buf);
-- sprintf(buf, "%s\tconfig = %s\n", buf, k[i]->action);
-- sprintf(buf, "%send\n\n", buf);
-- fputs(buf, stream);
-- memset(&buf, 0, sizeof(buf));
-+ fprintf(stream, "# %s\n"
-+ "begin\n"
-+ "\tremote = xxxxx\n"
-+ "\tbutton = xxxxx\n"
-+ "\tprog = xine\n"
-+ "\trepeat = 0\n"
-+ "\tconfig = %s\n"
-+ "end\n\n", k[i]->comment, k[i]->action);
- }
- }
- fprintf(stream, "##\n# End of xine key bindings.\n##\n");
-@@ -1028,33 +1026,31 @@
- fprintf(stream, "# Automatically generated by %s version %s.\n##\n\n", PACKAGE, VERSION);
-
- for(k = kbt->entry, i = 0; k[i]->action != NULL; i++) {
-- snprintf(buf, sizeof(buf), "# %s\n", k[i]->comment);
-+ fprintf(stream, "# %s\n", k[i]->comment);
-
- if(k[i]->is_alias) {
-- sprintf(buf, "%sAlias {\n", buf);
-- sprintf(buf, "%s\tentry = %s\n", buf, k[i]->action);
-+ fprintf(stream, "Alias {\n"
-+ "\tentry = %s\n", k[i]->action);
- }
- else
-- sprintf(buf, "%s%s {\n", buf, k[i]->action);
-+ fprintf(stream, "%s {\n", k[i]->action);
-
-- sprintf(buf, "%s\tkey = %s\n", buf, k[i]->key);
-- sprintf(buf, "%s%s", buf, "\tmodifier = ");
-+ fprintf(stream, "\tkey = %s\n", k[i]->key);
-+ strcpy(buf, "\tmodifier = ");
- if(k[i]->modifier == KEYMOD_NOMOD)
-- sprintf(buf, "%s%s, ", buf, "none");
-+ strcat(buf, "none, ");
- if(k[i]->modifier & KEYMOD_CONTROL)
-- sprintf(buf, "%s%s, ", buf, "control");
-+ strcat(buf, "control, ");
- if(k[i]->modifier & KEYMOD_META)
-- sprintf(buf, "%s%s, ", buf, "meta");
-+ strcat(buf, "meta, ");
- if(k[i]->modifier & KEYMOD_MOD3)
-- sprintf(buf, "%s%s, ", buf, "mod3");
-+ strcat(buf, "mod3, ");
- if(k[i]->modifier & KEYMOD_MOD4)
-- sprintf(buf, "%s%s, ", buf, "mod4");
-+ strcat(buf, "mod4, ");
- if(k[i]->modifier & KEYMOD_MOD5)
-- sprintf(buf, "%s%s, ", buf, "mod5");
-- buf[strlen(buf) - 2] = '\n';
-- buf[strlen(buf) - 1] = '\0';
-- sprintf(buf, "%s%s", buf, "}\n\n");
-- fprintf(stream, "%s", buf);
-+ strcat(buf, "mod5, ");
-+ buf[strlen(buf) - 2] = '\0';
-+ fprintf(stream, "%s\n}\n\n", buf);
- memset(&buf, 0, sizeof(buf));
- }
- fprintf(stream, "##\n# End of xine key bindings.\n##\n");
-@@ -1267,31 +1263,35 @@
- memset(&shortcut, 0, sizeof(shortcut));
-
- if(gGui->shortcut_style == 0) {
-- if(kbe->modifier & KEYMOD_CONTROL)
-- sprintf(shortcut, "%s%s+", shortcut, _("Ctrl"));
-- if(kbe->modifier & KEYMOD_META)
-- sprintf(shortcut, "%s%s+", shortcut, _("Alt"));
-+ if(kbe->modifier & KEYMOD_CONTROL) {
-+ strcat(shortcut, _("Ctrl"));
-+ strcat(shortcut, "+");
-+ }
-+ if(kbe->modifier & KEYMOD_META) {
-+ strcat(shortcut, _("Alt"));
-+ strcat(shortcut, "+");
-+ }
- if(kbe->modifier & KEYMOD_MOD3)
-- sprintf(shortcut, "%s%s+", shortcut, "M3");
-+ strcat(shortcut, "M3+");
- if(kbe->modifier & KEYMOD_MOD4)
-- sprintf(shortcut, "%s%s+", shortcut, "M4");
-+ strcat(shortcut, "M4+");
- if(kbe->modifier & KEYMOD_MOD5)
-- sprintf(shortcut, "%s%s+", shortcut, "M5");
-+ strcat(shortcut, "M5+");
- }
- else {
- if(kbe->modifier & KEYMOD_CONTROL)
-- sprintf(shortcut, "%s%s-", shortcut, "C");
-+ strcat(shortcut, "C-");
- if(kbe->modifier & KEYMOD_META)
-- sprintf(shortcut, "%s%s-", shortcut, "M");
-+ strcat(shortcut, "M-");
- if(kbe->modifier & KEYMOD_MOD3)
-- sprintf(shortcut, "%s%s-", shortcut, "M3");
-+ strcat(shortcut, "M3-");
- if(kbe->modifier & KEYMOD_MOD4)
-- sprintf(shortcut, "%s%s-", shortcut, "M4");
-+ strcat(shortcut, "M4-");
- if(kbe->modifier & KEYMOD_MOD5)
-- sprintf(shortcut, "%s%s-", shortcut, "M5");
-+ strcat(shortcut, "M5-");
- }
-
-- sprintf(shortcut, "%s%s", shortcut, kbe->key);
-+ strcat(shortcut, kbe->key);
-
- return shortcut;
- }
-@@ -2486,23 +2486,23 @@
- sprintf(buf, "%s", "\\fBC\\fP");
- if(k[i]->modifier & KEYMOD_META) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD3) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM3\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM3\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD4) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM4\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM4\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD5) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM5\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM5\\fP");
- }
- printf("%s\\-", buf);
- }
-diff -ur xine-ui-0.99.3/src/xitk/kbindings_man.c xine-ui-0.99.3.sprintf/src/xitk/kbindings_man.c
---- xine-ui-0.99.3/src/xitk/kbindings_man.c 2004-12-16 08:14:08.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/kbindings_man.c 2005-07-06 12:12:21.000000000 -0700
-@@ -590,12 +590,12 @@
- char *header = _("The following key bindings pairs are identical:\n\n");
- len += strlen(header);
- kmsg = (char *) xine_xmalloc(len + 1);
-- sprintf(kmsg, "%s%s%c%s%c%s", header, action1,' ', dna, ' ', action2);
-+ sprintf(kmsg, "%s%s %s %s", header, action1, dna, action2);
- }
- else {
- len += 2;
- kmsg = (char *) realloc(kmsg, strlen(kmsg) + len + 1);
-- sprintf(kmsg, "%s%s%s%c%s%c%s", kmsg, ", ", action1, ' ', dna, ' ', action2);
-+ sprintf(kmsg+strlen(kmsg), ", %s %s %s", action1, dna, action2);
- }
- }
- }
-@@ -607,7 +607,7 @@
- char *footer = _(".\n\nWhat do you want to do ?\n");
-
- kmsg = (char *) realloc(kmsg, strlen(kmsg) + strlen(footer) + 1);
-- sprintf(kmsg, "%s%s", kmsg, footer);
-+ strcat(kmsg, footer);
-
- dump_error(gGui->verbosity, kmsg);
-
-@@ -1007,16 +1007,14 @@
-
- for(k = kbt->entry, i = 0; k[i]->action != NULL; i++) {
- if(!k[i]->is_alias) {
-- sprintf(buf, "# %s\n", k[i]->comment);
-- sprintf(buf, "%sbegin\n", buf);
-- sprintf(buf, "%s\tremote = xxxxx\n", buf);
-- sprintf(buf, "%s\tbutton = xxxxx\n", buf);
-- sprintf(buf, "%s\tprog = xine\n", buf);
-- sprintf(buf, "%s\trepeat = 0\n", buf);
-- sprintf(buf, "%s\tconfig = %s\n", buf, k[i]->action);
-- sprintf(buf, "%send\n\n", buf);
-- fputs(buf, stream);
-- memset(&buf, 0, sizeof(buf));
-+ fprintf(stream, "# %s\n"
-+ "begin\n"
-+ "\tremote = xxxxx\n"
-+ "\tbutton = xxxxx\n"
-+ "\tprog = xine\n"
-+ "\trepeat = 0\n"
-+ "\tconfig = %s\n"
-+ "end\n\n", k[i]->comment, k[i]->action);
- }
- }
- fprintf(stream, "##\n# End of xine key bindings.\n##\n");
-@@ -1028,33 +1026,31 @@
- fprintf(stream, "# Automatically generated by %s version %s.\n##\n\n", PACKAGE, VERSION);
-
- for(k = kbt->entry, i = 0; k[i]->action != NULL; i++) {
-- snprintf(buf, sizeof(buf), "# %s\n", k[i]->comment);
-+ fprintf(stream, "# %s\n", k[i]->comment);
-
- if(k[i]->is_alias) {
-- sprintf(buf, "%sAlias {\n", buf);
-- sprintf(buf, "%s\tentry = %s\n", buf, k[i]->action);
-+ fprintf(stream, "Alias {\n"
-+ "\tentry = %s\n", k[i]->action);
- }
- else
-- sprintf(buf, "%s%s {\n", buf, k[i]->action);
-+ fprintf(stream, "%s {\n", k[i]->action);
-
-- sprintf(buf, "%s\tkey = %s\n", buf, k[i]->key);
-- sprintf(buf, "%s%s", buf, "\tmodifier = ");
-+ fprintf(stream, "\tkey = %s\n", k[i]->key);
-+ strcpy(buf, "\tmodifier = ");
- if(k[i]->modifier == KEYMOD_NOMOD)
-- sprintf(buf, "%s%s, ", buf, "none");
-+ sprintf(buf+strlen(buf), "%s, ", "none");
- if(k[i]->modifier & KEYMOD_CONTROL)
-- sprintf(buf, "%s%s, ", buf, "control");
-+ sprintf(buf+strlen(buf), "%s, ", "control");
- if(k[i]->modifier & KEYMOD_META)
-- sprintf(buf, "%s%s, ", buf, "meta");
-+ sprintf(buf+strlen(buf), "%s, ", "meta");
- if(k[i]->modifier & KEYMOD_MOD3)
-- sprintf(buf, "%s%s, ", buf, "mod3");
-+ sprintf(buf+strlen(buf), "%s, ", "mod3");
- if(k[i]->modifier & KEYMOD_MOD4)
-- sprintf(buf, "%s%s, ", buf, "mod4");
-+ sprintf(buf+strlen(buf), "%s, ", "mod4");
- if(k[i]->modifier & KEYMOD_MOD5)
-- sprintf(buf, "%s%s, ", buf, "mod5");
-- buf[strlen(buf) - 2] = '\n';
-- buf[strlen(buf) - 1] = '\0';
-- sprintf(buf, "%s%s", buf, "}\n\n");
-- fprintf(stream, "%s", buf);
-+ sprintf(buf+strlen(buf), "%s, ", "mod5");
-+ buf[strlen(buf) - 2] = '\0';
-+ fprintf(stream, "%s\n}\n\n", buf);
- memset(&buf, 0, sizeof(buf));
- }
- fprintf(stream, "##\n# End of xine key bindings.\n##\n");
-@@ -1267,31 +1263,35 @@
- memset(&shortcut, 0, sizeof(shortcut));
-
- if(gGui->shortcut_style == 0) {
-- if(kbe->modifier & KEYMOD_CONTROL)
-- sprintf(shortcut, "%s%s+", shortcut, _("Ctrl"));
-- if(kbe->modifier & KEYMOD_META)
-- sprintf(shortcut, "%s%s+", shortcut, _("Alt"));
-+ if(kbe->modifier & KEYMOD_CONTROL) {
-+ strcat(shortcut, _("Ctrl"));
-+ strcat(shortcut, "+");
-+ }
-+ if(kbe->modifier & KEYMOD_META) {
-+ strcat(shortcut, _("Alt"));
-+ strcat(shortcut, "+");
-+ }
- if(kbe->modifier & KEYMOD_MOD3)
-- sprintf(shortcut, "%s%s+", shortcut, "M3");
-+ strcat(shortcut, "M3+");
- if(kbe->modifier & KEYMOD_MOD4)
-- sprintf(shortcut, "%s%s+", shortcut, "M4");
-+ strcat(shortcut, "M4+");
- if(kbe->modifier & KEYMOD_MOD5)
-- sprintf(shortcut, "%s%s+", shortcut, "M5");
-+ strcat(shortcut, "M5+");
- }
- else {
- if(kbe->modifier & KEYMOD_CONTROL)
-- sprintf(shortcut, "%s%s-", shortcut, "C");
-+ strcat(shortcut, "C-");
- if(kbe->modifier & KEYMOD_META)
-- sprintf(shortcut, "%s%s-", shortcut, "M");
-+ strcat(shortcut, "M-");
- if(kbe->modifier & KEYMOD_MOD3)
-- sprintf(shortcut, "%s%s-", shortcut, "M3");
-+ strcat(shortcut, "M3-");
- if(kbe->modifier & KEYMOD_MOD4)
-- sprintf(shortcut, "%s%s-", shortcut, "M4");
-+ strcat(shortcut, "M4-");
- if(kbe->modifier & KEYMOD_MOD5)
-- sprintf(shortcut, "%s%s-", shortcut, "M5");
-+ strcat(shortcut, "M5-");
- }
-
-- sprintf(shortcut, "%s%s", shortcut, kbe->key);
-+ strcat(shortcut, kbe->key);
-
- return shortcut;
- }
-@@ -2486,23 +2486,23 @@
- sprintf(buf, "%s", "\\fBC\\fP");
- if(k[i]->modifier & KEYMOD_META) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD3) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM3\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM3\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD4) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM4\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM4\\fP");
- }
- if(k[i]->modifier & KEYMOD_MOD5) {
- if(strlen(buf))
-- sprintf(buf, "%s%s", buf, "\\-");
-- sprintf(buf, "%s%s", buf, "\\fBM5\\fP");
-+ strcat(buf, "\\-");
-+ strcat(buf, "\\fBM5\\fP");
- }
- printf("%s\\-", buf);
- }
-diff -ur xine-ui-0.99.3/src/xitk/main.c xine-ui-0.99.3.sprintf/src/xitk/main.c
---- xine-ui-0.99.3/src/xitk/main.c 2004-12-15 13:10:45.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/main.c 2005-07-06 12:56:14.000000000 -0700
-@@ -463,11 +463,12 @@
- len = strlen(buffer);
-
- if((len + (strlen(plugin) + 3)) < 80) {
-- sprintf(buffer, "%s%s%s", buffer, (strlen(buffer) == strlen(blanks)) ? "" : ", ", plugin);
-+ if (len != strlen(blanks))
-+ strcat(buffer, ", ");
-+ strcat(buffer, plugin);
- }
- else {
-- printf(buffer);
-- printf(",\n");
-+ printf("%s,\n", buffer);
- snprintf(buffer, sizeof(buffer), "%s%s", blanks, plugin);
- }
-
-@@ -1090,9 +1091,9 @@
- "%s:", _("*drum roll*, xine lib wants to take your attention "
- "to deliver an important message to you ;-):"));
- if(data->explanation)
-- sprintf(buffer, "%s %s %s", buffer, (char *) data + data->explanation, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " %s %s", (char *) data + data->explanation, (char *) data + data->parameters);
- else
-- sprintf(buffer, "%s %s", buffer, _("No Information available."));
-+ sprintf(buffer+strlen(buffer), " %s", _("No Information available."));
-
- break;
-
-@@ -1101,14 +1102,14 @@
- snprintf(buffer, sizeof(buffer), "%s", _("The host you're trying to connect is unknown.\n"
- "Check the validity of the specified hostname."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (device name) */
- case XINE_MSG_UNKNOWN_DEVICE:
- snprintf(buffer, sizeof(buffer), "%s", _("The device name you specified seems invalid."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* none */
-@@ -1116,21 +1117,21 @@
- snprintf(buffer, sizeof(buffer), "%s", _("The network looks unreachable.\nCheck your network "
- "setup and/or the server name."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (host name) */
- case XINE_MSG_CONNECTION_REFUSED:
- snprintf(buffer, sizeof(buffer), "%s", _("The connection was refused.\nCheck the host name."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (file name or mrl) */
- case XINE_MSG_FILE_NOT_FOUND:
- snprintf(buffer, sizeof(buffer), "%s", _("The specified file or mrl is not found. Please check it twice."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (device/file/mrl) */
-@@ -1139,27 +1140,27 @@
- "rights for this, or source doesn't contain data "
- "(e.g: not disc in drive)."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (library/decoder) */
- case XINE_MSG_LIBRARY_LOAD_ERROR:
- snprintf(buffer, sizeof(buffer), "%s", _("A problem occur while loading a library or a decoder"));
- if(data->explanation)
-- sprintf(buffer, "%s: %s", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), ": %s", (char *) data + data->parameters);
- break;
-
- /* none */
- case XINE_MSG_ENCRYPTED_SOURCE:
- snprintf(buffer, sizeof(buffer), "%s", _("The source seems encrypted, and can't be read."));
- if(!strncasecmp(gGui->mmk.mrl, "dvd:/", 5)) {
-- sprintf(buffer, "%s%s", buffer, _("\nYour DVD is probably crypted. "
-- "According to your country laws, you can or can't "
-- "install/use libdvdcss to be able to read this disc, "
-- "which you bought."));
-+ strcat(buffer, _("\nYour DVD is probably crypted. "
-+ "According to your country laws, you can or can't "
-+ "install/use libdvdcss to be able to read this disc, "
-+ "which you bought."));
- }
- if(data->explanation)
-- sprintf(buffer, "%s (%s)", buffer, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s)", (char *) data + data->parameters);
- break;
-
- /* (warning message) */
-@@ -1180,17 +1181,17 @@
- default:
- snprintf(buffer, sizeof(buffer), "%s", _("*sight*, unkown error."));
- if(data->explanation)
-- sprintf(buffer, "%s (%s %s)", buffer, (char *) data + data->explanation, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), " (%s %s)", (char *) data + data->explanation, (char *) data + data->parameters);
- break;
- }
-
- if(gGui->verbosity >= XINE_VERBOSITY_DEBUG) {
-- sprintf(buffer, "%s\n\n[", buffer);
-+ strcat(buffer, "\n\n[");
-
- if(data->explanation)
-- sprintf(buffer, "%s'%s' '%s'", buffer, (char *) data + data->explanation, (char *) data + data->parameters);
-+ sprintf(buffer+strlen(buffer), "'%s' '%s'", (char *) data + data->explanation, (char *) data + data->parameters);
-
-- sprintf(buffer, "%s]", buffer);
-+ strcat(buffer, "]");
- }
-
- if(strlen(buffer))
-diff -ur xine-ui-0.99.3/src/xitk/mediamark.c xine-ui-0.99.3.sprintf/src/xitk/mediamark.c
---- xine-ui-0.99.3/src/xitk/mediamark.c 2004-12-15 23:14:26.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/mediamark.c 2005-07-06 12:58:03.000000000 -0700
-@@ -561,7 +561,7 @@
- if((buffer[strlen(buffer) - 1] == '/') && (*ln == '/'))
- buffer[strlen(buffer) - 1] = '\0';
-
-- sprintf(buffer, "%s%s", buffer, ln);
-+ strcat(buffer, ln);
-
- if(_file_exist(buffer))
- entry = buffer;
-@@ -681,7 +681,7 @@
- if((buffer[strlen(buffer) - 1] == '/') && (*ln == '/'))
- buffer[strlen(buffer) - 1] = '\0';
-
-- sprintf(buffer, "%s%s", buffer, ln);
-+ strcat(buffer, ln);
-
- if(_file_exist(buffer))
- entry = buffer;
-@@ -774,7 +774,7 @@
- if((buffer[strlen(buffer) - 1] == '/') && (*ln == '/'))
- buffer[strlen(buffer) - 1] = '\0';
-
-- sprintf(buffer, "%s%s", buffer, ln);
-+ strcat(buffer, ln);
-
- if(_file_exist(buffer))
- entry = buffer;
-@@ -1125,7 +1125,7 @@
- sprintf(real_title, "%s", atitle);
-
- if(aauthor && strlen(aauthor))
-- sprintf(real_title, "%s (%s)", real_title, aauthor);
-+ sprintf(real_title+strlen(real_title), " (%s)", aauthor);
- }
-
- mmk = (mediamark_t **) realloc(mmk, sizeof(mediamark_t *) * (entries_asx + 2));
-diff -ur xine-ui-0.99.3/src/xitk/network.c xine-ui-0.99.3.sprintf/src/xitk/network.c
---- xine-ui-0.99.3/src/xitk/network.c 2004-08-24 13:06:26.000000000 -0700
-+++ xine-ui-0.99.3.sprintf/src/xitk/network.c 2005-07-06 13:08:58.000000000 -0700
-@@ -550,7 +550,7 @@
- /* Each line sent is '\n' terminated */
- if(cr) {
- if((buf[strlen(buf)] == '\0') && (buf[strlen(buf) - 1] != '\n'))
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- }
-
- return _sock_write(socket, buf, strlen(buf));
-@@ -746,15 +746,15 @@
- while(session_commands[i]->command != NULL) {
- if(session_commands[i]->enable) {
- if((curpos + maxlen) >= 80) {
-- sprintf(buf, "%s\n ", buf);
-+ strcat(buf, "\n ");
- curpos = 7;
- }
-
-- sprintf(buf, "%s%s", buf, session_commands[i]->command);
-+ strcat(buf, session_commands[i]->command);
- curpos += strlen(session_commands[i]->command);
-
- for(j = 0; j < (maxlen - strlen(session_commands[i]->command)); j++) {
-- sprintf(buf, "%s ", buf);
-+ strcat(buf, " ");
- curpos++;
- }
- }
-@@ -1111,10 +1111,9 @@
- memset(&buf, 0, sizeof(buf));
-
- for(i = 0; i < num_commands; i++) {
-- if(strlen(buf))
-- sprintf(buf, "%s %s", buf, commands[i]);
-- else
-- snprintf(buf, sizeof(buf), "%s", commands[i]);
-+ if(i)
-+ strcat(buf, " ");
-+ strcat(buf, commands[i]);
- }
-
- client_handle_command(session, buf);
-@@ -1709,11 +1708,11 @@
-
- while(commands[i].command != NULL) {
- if(commands[i].public) {
-- sprintf(buf, "%s\t%s", buf, commands[i].command);
-+ sprintf(buf+strlen(buf), "\t%s", commands[i].command);
- }
- i++;
- }
-- sprintf(buf, "%s.\n", buf);
-+ strcat(buf, ".\n");
- sock_write(client_info->socket, buf);
- }
-
-@@ -1744,22 +1743,22 @@
- while(commands[i].command != NULL) {
- if(commands[i].public) {
- if((curpos + maxlen) >= 80) {
-- sprintf(buf, "%s\n ", buf);
-+ strcat(buf, "\n ");
- curpos = 7;
- }
-
-- sprintf(buf, "%s%s", buf, commands[i].command);
-+ strcat(buf, commands[i].command);
- curpos += strlen(commands[i].command);
-
- for(j = 0; j < (maxlen - strlen(commands[i].command)); j++) {
-- sprintf(buf, "%s ", buf);
-+ strcat(buf, " ");
- curpos++;
- }
- }
- i++;
- }
-
-- sprintf(buf, "%s\n", buf);
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else {
-@@ -2091,11 +2090,11 @@
- status = xine_get_status(gGui->stream);
-
- if(status <= XINE_STATUS_QUIT)
-- sprintf(buf, "%s%s", buf, status_struct[status].name);
-+ strcat(buf, status_struct[status].name);
- else
-- sprintf(buf, "%s%s", buf, "*UNKNOWN*");
-+ strcat(buf, "*UNKNOWN*");
-
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else if(is_arg_contain(client_info, 1, "speed")) {
-@@ -2111,11 +2110,11 @@
- }
-
- if(i < ((sizeof(speeds_struct) / sizeof(speeds_struct[0])) - 1))
-- sprintf(buf, "%s%s", buf, speeds_struct[i].name);
-+ strcat(buf, speeds_struct[i].name);
- else
-- sprintf(buf, "%s%s", buf, "*UNKNOWN*");
-+ strcat(buf, "*UNKNOWN*");
-
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else if(is_arg_contain(client_info, 1, "position")) {
-@@ -2149,26 +2148,26 @@
-
- switch(gGui->playlist.loop) {
- case PLAYLIST_LOOP_NO_LOOP:
-- sprintf(buf, "%s%s", buf, "'No Loop'");
-+ strcat(buf, "'No Loop'");
- break;
- case PLAYLIST_LOOP_LOOP:
-- sprintf(buf, "%s%s", buf, "'Loop'");
-+ strcat(buf, "'Loop'");
- break;
- case PLAYLIST_LOOP_REPEAT:
-- sprintf(buf, "%s%s", buf, "'Repeat'");
-+ strcat(buf, "'Repeat'");
- break;
- case PLAYLIST_LOOP_SHUFFLE:
-- sprintf(buf, "%s%s", buf, "'Shuffle'");
-+ strcat(buf, "'Shuffle'");
- break;
- case PLAYLIST_LOOP_SHUF_PLUS:
-- sprintf(buf, "%s%s", buf, "'Shuffle forever'");
-+ strcat(buf, "'Shuffle forever'");
- break;
- default:
-- sprintf(buf, "%s%s", buf, "'!!Unknown!!'");
-+ strcat(buf, "'!!Unknown!!'");
- break;
- }
-
-- sprintf(buf, "%s.\n", buf);
-+ strcat(buf, ".\n");
- sock_write(client_info->socket, buf);
- }
- }
-diff -ur xine-ui-0.99.3/src/xitk/osd.c xine-ui-0.99.3.sprintf/src/xitk/osd.c
---- xine-ui-0.99.3/src/xitk/osd.c 2004-11-15 13:43:20.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/osd.c 2005-07-06 17:20:30.000000000 -0700
-@@ -338,34 +338,34 @@
- len = strlen(buffer);
- switch(audiochannel) {
- case -2:
-- sprintf(buffer, "%s%s", buffer, "off");
-+ strcat(buffer, "off");
- break;
- case -1:
- if(!xine_get_audio_lang (gGui->stream, audiochannel, &buffer[len]))
-- sprintf(buffer, "%s%s", buffer, "auto");
-+ strcat(buffer, "auto");
- break;
- default:
- if(!xine_get_audio_lang (gGui->stream, audiochannel, &buffer[len]))
-- sprintf(buffer, "%s%3d", buffer, audiochannel);
-+ sprintf(buffer+strlen(buffer), "%3d", audiochannel);
- break;
- }
-
-- sprintf(buffer, "%s%s", buffer, ", Spu: ");
-+ strcat(buffer, ", Spu: ");
- len = strlen(buffer);
- switch (spuchannel) {
- case -2:
-- sprintf(buffer, "%s%s", buffer, "off");
-+ strcat(buffer, "off");
- break;
- case -1:
- if(!xine_get_spu_lang (gGui->stream, spuchannel, &buffer[len]))
-- sprintf(buffer, "%s%s", buffer, "auto");
-+ strcat(buffer, "auto");
- break;
- default:
- if(!xine_get_spu_lang (gGui->stream, spuchannel, &buffer[len]))
-- sprintf(buffer, "%s%3d", buffer, spuchannel);
-+ sprintf(buffer+strlen(buffer), "%3d", spuchannel);
- break;
- }
-- sprintf(buffer, "%s.", buffer);
-+ strcat(buffer, ".");
- xine_osd_draw_text(gGui->osd.sinfo.osd[0], x, y, buffer, XINE_OSD_TEXT1);
- xine_osd_get_text_size(gGui->osd.sinfo.osd[0], buffer, &w, &h);
- if(w > osdw)
-@@ -384,12 +384,12 @@
- int totaldays;
-
- totaldays = totaltime / (3600 * 24);
-- sprintf(buffer, "%s(%.0f%%) %s ", buffer, ((float)playedtime / (float)totaltime) * 100, _("of"));
-+ sprintf(buffer+strlen(buffer), "(%.0f%%) %s ", ((float)playedtime / (float)totaltime) * 100, _("of"));
-
- if(totaldays > 0)
-- sprintf(buffer, "%s%d::%02d", buffer, totaldays, totaltime / 3600);
-+ sprintf(buffer+strlen(buffer), "%d::%02d", totaldays, totaltime / 3600);
- else
-- sprintf(buffer, "%s%d:%02d:%02d", buffer, totaltime / 3600, (totaltime % 3600) / 60, totaltime % 60);
-+ sprintf(buffer+strlen(buffer), "%d:%02d:%02d", totaltime / 3600, (totaltime % 3600) / 60, totaltime % 60);
- }
-
- xine_osd_draw_text(gGui->osd.sinfo.osd[0], x, y, buffer, XINE_OSD_TEXT1);
-diff -ur xine-ui-0.99.3/src/xitk/stream_infos.c xine-ui-0.99.3.sprintf/src/xitk/stream_infos.c
---- xine-ui-0.99.3/src/xitk/stream_infos.c 2004-12-15 13:10:46.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/stream_infos.c 2005-07-06 17:21:22.000000000 -0700
-@@ -265,11 +265,11 @@
- if((aartist && strlen(aartist)) || (aalbum && strlen(aalbum))) {
- strcat(ident, " (");
- if(aartist && strlen(aartist))
-- sprintf(ident, "%s%s", ident, aartist);
-+ strcat(ident, aartist);
- if((aartist && strlen(aartist)) && (aalbum && strlen(aalbum)))
- strcat(ident, " - ");
- if(aalbum && strlen(aalbum))
-- sprintf(ident, "%s%s", ident, aalbum);
-+ strcat(ident, aalbum);
- strcat(ident, ")");
- }
- }
-diff -ur xine-ui-0.99.3/src/xitk/viewlog.c xine-ui-0.99.3.sprintf/src/xitk/viewlog.c
---- xine-ui-0.99.3/src/xitk/viewlog.c 2004-12-15 13:10:46.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/viewlog.c 2005-07-06 17:23:03.000000000 -0700
-@@ -229,7 +229,7 @@
- break;
-
- default:
-- sprintf(buf, "%s%c", buf, *p);
-+ sprintf(buf+strlen(buf), "%c", *p);
- break;
- }
-
-diff -ur xine-ui-0.99.3/src/xitk/xine-remote.c xine-ui-0.99.3.sprintf/src/xitk/xine-remote.c
---- xine-ui-0.99.3/src/xitk/xine-remote.c 2004-08-24 13:06:26.000000000 -0700
-+++ xine-ui-0.99.3.sprintf/src/xitk/xine-remote.c 2005-07-06 17:36:35.000000000 -0700
-@@ -550,7 +550,7 @@
- /* Each line sent is '\n' terminated */
- if(cr) {
- if((buf[strlen(buf)] == '\0') && (buf[strlen(buf) - 1] != '\n'))
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- }
-
- return _sock_write(socket, buf, strlen(buf));
-@@ -746,15 +746,15 @@
- while(session_commands[i]->command != NULL) {
- if(session_commands[i]->enable) {
- if((curpos + maxlen) >= 80) {
-- sprintf(buf, "%s\n ", buf);
-+ strcat(buf, "\n ");
- curpos = 7;
- }
-
-- sprintf(buf, "%s%s", buf, session_commands[i]->command);
-+ strcat(buf, session_commands[i]->command);
- curpos += strlen(session_commands[i]->command);
-
- for(j = 0; j < (maxlen - strlen(session_commands[i]->command)); j++) {
-- sprintf(buf, "%s ", buf);
-+ strcat(buf, " ");
- curpos++;
- }
- }
-@@ -1111,10 +1111,9 @@
- memset(&buf, 0, sizeof(buf));
-
- for(i = 0; i < num_commands; i++) {
-- if(strlen(buf))
-- sprintf(buf, "%s %s", buf, commands[i]);
-- else
-- snprintf(buf, sizeof(buf), "%s", commands[i]);
-+ if(i)
-+ strcat(buf, " ");
-+ strcat(buf, commands[i]);
- }
-
- client_handle_command(session, buf);
-@@ -1709,11 +1708,11 @@
-
- while(commands[i].command != NULL) {
- if(commands[i].public) {
-- sprintf(buf, "%s\t%s", buf, commands[i].command);
-+ sprintf(buf+strlen(buf), "\t%s", commands[i].command);
- }
- i++;
- }
-- sprintf(buf, "%s.\n", buf);
-+ strcat(buf, ".\n");
- sock_write(client_info->socket, buf);
- }
-
-@@ -1744,22 +1743,22 @@
- while(commands[i].command != NULL) {
- if(commands[i].public) {
- if((curpos + maxlen) >= 80) {
-- sprintf(buf, "%s\n ", buf);
-+ strcat(buf, "\n ");
- curpos = 7;
- }
-
-- sprintf(buf, "%s%s", buf, commands[i].command);
-+ strcat(buf, commands[i].command);
- curpos += strlen(commands[i].command);
-
- for(j = 0; j < (maxlen - strlen(commands[i].command)); j++) {
-- sprintf(buf, "%s ", buf);
-+ strcat(buf, " ");
- curpos++;
- }
- }
- i++;
- }
-
-- sprintf(buf, "%s\n", buf);
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else {
-@@ -2091,11 +2090,11 @@
- status = xine_get_status(gGui->stream);
-
- if(status <= XINE_STATUS_QUIT)
-- sprintf(buf, "%s%s", buf, status_struct[status].name);
-+ strcat(buf, status_struct[status].name);
- else
-- sprintf(buf, "%s%s", buf, "*UNKNOWN*");
-+ strcat(buf, "*UNKNOWN*");
-
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else if(is_arg_contain(client_info, 1, "speed")) {
-@@ -2111,11 +2110,11 @@
- }
-
- if(i < ((sizeof(speeds_struct) / sizeof(speeds_struct[0])) - 1))
-- sprintf(buf, "%s%s", buf, speeds_struct[i].name);
-+ strcat(buf, speeds_struct[i].name);
- else
-- sprintf(buf, "%s%s", buf, "*UNKNOWN*");
-+ strcat(buf, "*UNKNOWN*");
-
-- sprintf(buf, "%s%c", buf, '\n');
-+ strcat(buf, "\n");
- sock_write(client_info->socket, buf);
- }
- else if(is_arg_contain(client_info, 1, "position")) {
-@@ -2149,26 +2148,26 @@
-
- switch(gGui->playlist.loop) {
- case PLAYLIST_LOOP_NO_LOOP:
-- sprintf(buf, "%s%s", buf, "'No Loop'");
-+ strcat(buf, "'No Loop'");
- break;
- case PLAYLIST_LOOP_LOOP:
-- sprintf(buf, "%s%s", buf, "'Loop'");
-+ strcat(buf, "'Loop'");
- break;
- case PLAYLIST_LOOP_REPEAT:
-- sprintf(buf, "%s%s", buf, "'Repeat'");
-+ strcat(buf, "'Repeat'");
- break;
- case PLAYLIST_LOOP_SHUFFLE:
-- sprintf(buf, "%s%s", buf, "'Shuffle'");
-+ strcat(buf, "'Shuffle'");
- break;
- case PLAYLIST_LOOP_SHUF_PLUS:
-- sprintf(buf, "%s%s", buf, "'Shuffle forever'");
-+ strcat(buf, "'Shuffle forever'");
- break;
- default:
-- sprintf(buf, "%s%s", buf, "'!!Unknown!!'");
-+ strcat(buf, "'!!Unknown!!'");
- break;
- }
-
-- sprintf(buf, "%s.\n", buf);
-+ strcat(buf, ".\n");
- sock_write(client_info->socket, buf);
- }
- }
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/image.c xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/image.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/image.c 2004-12-16 13:35:30.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/image.c 2005-07-06 17:37:27.000000000 -0700
-@@ -1334,7 +1334,7 @@
- /* Cut title, add three dots a the end */
- nchar -= 4;
- snprintf(buf, nchar, "%s", title);
-- sprintf(buf, "%s%s", buf, "...");
-+ strcat(buf, "...");
- }
- else
- sprintf(buf, "%s", title);
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/skin.c xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/skin.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/skin.c 2004-11-22 00:45:26.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/skin.c 2005-07-06 17:40:32.000000000 -0700
-@@ -149,44 +149,44 @@
- snprintf(ppath, sizeof(ppath), "%s", skonfig->path);
- if((z = strrchr(ppath, '/')) != NULL) {
- *z = '\0';
-- sprintf(buf2, "%s%s", buf2, ppath);
-+ strcat(buf2, ppath);
- }
- }
- }
- else if(!strncmp("SKIN_VERSION", var, strlen(var))) {
- if(skonfig->version >= 0)
-- sprintf(buf2, "%s%d", buf2, skonfig->version);
-+ sprintf(buf2+strlen(buf2), "%d", skonfig->version);
- }
- else if(!strncmp("SKIN_AUTHOR", var, strlen(var))) {
- if(skonfig->author)
-- sprintf(buf2, "%s%s", buf2, skonfig->author);
-+ strcat(buf2, skonfig->author);
- }
- else if(!strncmp("SKIN_PATH", var, strlen(var))) {
- if(skonfig->path)
-- sprintf(buf2, "%s%s", buf2, skonfig->path);
-+ strcat(buf2, skonfig->path);
- }
- else if(!strncmp("SKIN_NAME", var, strlen(var))) {
- if(skonfig->name)
-- sprintf(buf2, "%s%s", buf2, skonfig->name);
-+ strcat(buf2, skonfig->name);
- }
- else if(!strncmp("SKIN_DATE", var, strlen(var))) {
- if(skonfig->date)
-- sprintf(buf2, "%s%s", buf2, skonfig->date);
-+ strcat(buf2, skonfig->date);
- }
- else if(!strncmp("SKIN_URL", var, strlen(var))) {
- if(skonfig->url)
-- sprintf(buf2, "%s%s", buf2, skonfig->url);
-+ strcat(buf2, skonfig->url);
- }
- else if(!strncmp("HOME", var, strlen(var))) {
- if(skonfig->url)
-- sprintf(buf2, "%s%s", buf2, xitk_get_homedir());
-+ strcat(buf2, xitk_get_homedir());
- }
- /* else ignore */
- }
- break;
-
- default:
-- sprintf(buf2, "%s%c", buf2, *p);
-+ sprintf(buf2+strlen(buf2), "%c", *p);
- break;
- }
- p++;
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/xitk.c xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/xitk.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/xitk.c 2004-12-15 13:10:48.000000000 -0800
-+++ xine-ui-0.99.3.sprintf/src/xitk/xine-toolkit/xitk.c 2005-07-07 01:32:18.000000000 -0700
-@@ -1828,7 +1828,7 @@
- gXitk->use_xshm = 0;
- else {
- XShmDetach(display, &shminfo);
-- sprintf(buffer, "%s%s", buffer, "[XShm]");
-+ strcat(buffer, "[XShm]");
- }
-
- XDestroyImage(xim);
-@@ -1844,12 +1844,12 @@
- #endif
-
- #ifdef WITH_XFT
-- sprintf(buffer, "%s%s", buffer, "[XFT]");
-+ strcat(buffer, "[XFT]");
- #elif defined(WITH_XMB)
-- sprintf(buffer, "%s%s", buffer, "[XMB]");
-+ strcat(buffer, "[XMB]");
- #endif
-
-- sprintf(buffer, "%s%s", buffer, " ]-");
-+ strcat(buffer, " ]-");
-
- if(verbosity)
- printf(buffer);
Deleted: trunk/rpms/xine/xine-ui-0.99.3-uifixups.patch
===================================================================
--- trunk/rpms/xine/xine-ui-0.99.3-uifixups.patch 2007-05-04 11:33:12 UTC (rev 5366)
+++ trunk/rpms/xine/xine-ui-0.99.3-uifixups.patch 2007-05-04 15:33:27 UTC (rev 5367)
@@ -1,104 +0,0 @@
-diff -ur xine-ui-0.99.3/src/xitk/help.c xine-ui-0.99.3-uifixups/src/xitk/help.c
---- xine-ui-0.99.3/src/xitk/help.c 2004-12-15 13:10:44.000000000 -0800
-+++ xine-ui-0.99.3-uifixups/src/xitk/help.c 2005-07-07 15:44:39.000000000 -0700
-@@ -392,7 +392,7 @@
- xitk_list_append_content ((XITK_WIDGET_LIST_LIST(help->widget_list)),
- (help->tabs =
- xitk_noskin_tabs_create(help->widget_list,
-- &tab, 20, 24, WINDOW_WIDTH - 40, tabsfontname)));
-+ &tab, 20, 24, WINDOW_WIDTH - 40, 28, tabsfontname)));
-
- xitk_enable_and_show_widget(help->tabs);
-
-diff -ur xine-ui-0.99.3/src/xitk/setup.c xine-ui-0.99.3-uifixups/src/xitk/setup.c
---- xine-ui-0.99.3/src/xitk/setup.c 2004-12-15 13:10:46.000000000 -0800
-+++ xine-ui-0.99.3-uifixups/src/xitk/setup.c 2005-07-12 17:49:15.000000000 -0700
-@@ -56,7 +56,7 @@
- int lbearing, rbearing, width, ascent, descent; \
- xitk_font_t *fs; \
- \
-- image = xitk_image_create_image(gGui->imlib_data, FRAME_WIDTH + 1, FRAME_HEIGHT + 1); \
-+ image = xitk_image_create_image(gGui->imlib_data, FRAME_WIDTH + 1, FRAME_HEIGHT + 2); \
- \
- fs = xitk_font_load_font(gGui->display, boldfontname); \
- xitk_font_set_font(fs, (XITK_WIDGET_LIST_GC(setup->widget_list))); \
-@@ -1006,7 +1006,7 @@
- tab.userdata = NULL;
- xitk_list_append_content ((XITK_WIDGET_LIST_LIST(setup->widget_list)),
- (setup->tabs =
-- xitk_noskin_tabs_create(setup->widget_list, &tab, 20, 24, WINDOW_WIDTH - 40, tabsfontname)));
-+ xitk_noskin_tabs_create(setup->widget_list, &tab, 20, 24, WINDOW_WIDTH - 40, 28, tabsfontname)));
-
- xitk_enable_and_show_widget(setup->tabs);
-
-@@ -1047,7 +1047,6 @@
-
- if(rpos != setup->first_displayed) {
- setup->first_displayed = rpos;
-- setup_clear_tab();
- setup_paint_widgets();
- }
- }
-diff -ur xine-ui-0.99.3/src/xitk/viewlog.c xine-ui-0.99.3-uifixups/src/xitk/viewlog.c
---- xine-ui-0.99.3/src/xitk/viewlog.c 2004-12-15 13:10:46.000000000 -0800
-+++ xine-ui-0.99.3-uifixups/src/xitk/viewlog.c 2005-07-07 15:44:39.000000000 -0700
-@@ -319,7 +319,7 @@
- tab.userdata = NULL;
- xitk_list_append_content ((XITK_WIDGET_LIST_LIST(viewlog->widget_list)),
- (viewlog->tabs =
-- xitk_noskin_tabs_create(viewlog->widget_list, &tab, 20, 24, WINDOW_WIDTH - 40, tabsfontname)));
-+ xitk_noskin_tabs_create(viewlog->widget_list, &tab, 20, 24, WINDOW_WIDTH - 40, 28, tabsfontname)));
- xitk_enable_and_show_widget(viewlog->tabs);
-
- bg = xitk_image_create_xitk_pixmap(gGui->imlib_data, WINDOW_WIDTH, WINDOW_HEIGHT);
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/tabs.c xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/tabs.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/tabs.c 2004-04-13 12:55:50.000000000 -0700
-+++ xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/tabs.c 2005-07-07 15:44:39.000000000 -0700
-@@ -323,7 +323,8 @@
- */
- xitk_widget_t *xitk_noskin_tabs_create(xitk_widget_list_t *wl,
- xitk_tabs_widget_t *t,
-- int x, int y, int width, char *fontname) {
-+ int x, int y, int width, int height,
-+ char *fontname) {
- xitk_widget_t *mywidget;
- tabs_private_data_t *private_data;
-
-@@ -367,7 +368,10 @@
- XITK_WIDGET_INIT(&lb, t->imlibdata);
- XITK_WIDGET_INIT(&b, t->imlibdata);
-
-- private_data->bheight = fheight * 2;
-+ if (height == 0)
-+ private_data->bheight = fheight * 2;
-+ else
-+ private_data->bheight = height;
-
- for(i = 0; i < t->num_entries; i++) {
-
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/test.c xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/test.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/test.c 2004-07-25 17:43:47.000000000 -0700
-+++ xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/test.c 2005-07-07 15:44:39.000000000 -0700
-@@ -509,7 +509,7 @@
- t.userdata = NULL;
- xitk_list_append_content (XITK_WIDGET_LIST_LIST(test->widget_list),
- (test->tabs =
-- xitk_noskin_tabs_create(test->widget_list, &t, x, y, w, fontname)));
-+ xitk_noskin_tabs_create(test->widget_list, &t, x, y, w, 0, fontname)));
- xitk_enable_and_show_widget(test->tabs);
-
- }
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/xitk.h xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/xitk.h
---- xine-ui-0.99.3/src/xitk/xine-toolkit/xitk.h 2004-12-16 13:35:30.000000000 -0800
-+++ xine-ui-0.99.3-uifixups/src/xitk/xine-toolkit/xitk.h 2005-07-07 15:44:39.000000000 -0700
-@@ -2351,7 +2351,8 @@
-
- xitk_widget_t *xitk_noskin_tabs_create(xitk_widget_list_t *wl,
- xitk_tabs_widget_t *t,
-- int x, int y, int width, char *fontname);
-+ int x, int y, int width, int height,
-+ char *fontname);
- int xitk_tabs_get_current_selected(xitk_widget_t *w);
- char *xitk_tabs_get_current_tab_selected(xitk_widget_t *w);
- void xitk_tabs_set_current_selected(xitk_widget_t *w, int select);
-
Deleted: trunk/rpms/xine/xine-ui-0.99.3-xftfontsize.patch
===================================================================
--- trunk/rpms/xine/xine-ui-0.99.3-xftfontsize.patch 2007-05-04 11:33:12 UTC (rev 5366)
+++ trunk/rpms/xine/xine-ui-0.99.3-xftfontsize.patch 2007-05-04 15:33:27 UTC (rev 5367)
@@ -1,64 +0,0 @@
-diff -ur xine-ui-0.99.3/src/xitk/xine-toolkit/font.c xine-ui-0.99.3-xftfontsize/src/xitk/xine-toolkit/font.c
---- xine-ui-0.99.3/src/xitk/xine-toolkit/font.c 2004-05-07 14:06:54.000000000 -0700
-+++ xine-ui-0.99.3-xftfontsize/src/xitk/xine-toolkit/font.c 2005-07-12 18:18:53.000000000 -0700
-@@ -320,7 +320,8 @@
- || strncmp(old_name, "-", 1) == 0 || strncmp(old_name, "*", 1) == 0) {
- char font[50];
- char style[15];
-- char *psize = "*", size[5], ptsize[5], pxsize[5];
-+ char ptsize[5], pxsize[5];
-+ int xft_pxsize;
-
- if( old_name[0] == '-' )
- old_name++;
-@@ -330,27 +331,18 @@
- sscanf( old_name, "%*[^-]-%*[^-]-%*[^-]-%*[^-]-%*[^-]-%*[^-]-%[^-]", pxsize);
- sscanf( old_name, "%*[^-]-%*[^-]-%*[^-]-%*[^-]-%*[^-]-%*[^-]-%*[^-]-%[^-]", ptsize);
-
-- /* Xft doesn't have lucida, which is a small font;
-- * thus we make whatever is chosen 2 sizes smaller */
-- if(strlen(pxsize) && strcmp(pxsize, "*"))
-- psize = pxsize;
-- else if(strlen(ptsize) && strcmp(ptsize, "*"))
-- psize = ptsize;
-+ if (!strcmp(style, "*"))
-+ style[0] = 0;
-
-- if( strcmp( font, "lucida" ) == 0 ) {
-- int sz = strtol(psize, &psize, 10);
-+ if(strlen(pxsize) && strcmp(pxsize, "*")) {
-+ /* Xft fonts usually come out looking slightly smaller at a given pixel
-+ * size, so bump the px size up by 1 to get a more consistent appearance.
-+ */
-+ xft_pxsize = atoi(pxsize) + 1;
-+ snprintf(new_name, sizeof(new_name)-5, "%s:pixelsize=%d:%s", font, xft_pxsize, style);
-+ } else if(strlen(ptsize) && strcmp(ptsize, "*"))
-+ snprintf(new_name, sizeof(new_name)-5, "%s-%s:%s", font, ptsize, style);
-
-- sz -= 2;
-- snprintf(size , sizeof(size), "%i", sz);
-- }
-- else
-- snprintf(size, sizeof(size), "%s", psize);
--
-- if( strcmp( style , "bold" ) != 0 )
-- snprintf( new_name, sizeof(new_name), "%s-%s", font, size );
-- else
-- snprintf( new_name, sizeof(new_name), "%s-%s:%s", font, size, style );
--
- return new_name;
- }
-
-@@ -1096,8 +1088,11 @@
- XUNLOCK(xtfs->display);
- free(encoded_text);
-
-+ /* Note: the fact that we have to fudge ascent so much means we're doing
-+ * something wrong somewhere. I don't have time to figure it out right now,
-+ * and this makes everything look about right onscreen, at least... --AS */
- if (width) *width = xft_extents.width;
-- if (ascent) *ascent = xtfs->font->ascent - 1;
-+ if (ascent) *ascent = xtfs->font->ascent - 4;
- if (descent) *descent = xtfs->font->descent;
- if (lbearing) *lbearing = 0;
- if (rbearing) *rbearing = 0;
Modified: trunk/rpms/xine/xine.spec
===================================================================
--- trunk/rpms/xine/xine.spec 2007-05-04 11:33:12 UTC (rev 5366)
+++ trunk/rpms/xine/xine.spec 2007-05-04 15:33:27 UTC (rev 5367)
@@ -108,7 +108,7 @@
%build
%configure \
-%{?_without_lirc:--disable-lirc}
+ %{?_without_lirc:--disable-lirc}
%{__make} %{?_smp_mflags}
More information about the svn-commits
mailing list