wok-next annotate xchat-plugin/stuff/xc286-smallfixes.diff @ rev 18087

Up: tazpanel (499)
author Aleksej Bobylev <al.bobylev@gmail.com>
date Sat May 23 17:21:51 2015 +0300 (2015-05-23)
parents
children
rev   line source
pascal@2866 1 #
pascal@2866 2 # Various small fixes from CVS that are considered safe to apply to 2.8.6.
pascal@2866 3 #
pascal@2866 4 --- xchat-2.8.6/src/common/cfgfiles.c 2008-02-05 21:02:47.000000000 +1100
pascal@2866 5 +++ xchat-2.8.6p1/src/common/cfgfiles.c 2008-06-15 13:45:43.000000000 +1000
pascal@2866 6 @@ -886,7 +886,6 @@
pascal@2866 7 set_showval (session *sess, const struct prefs *var, char *tbuf)
pascal@2866 8 {
pascal@2866 9 int len, dots, j;
pascal@2866 10 - static const char *offon[] = { "OFF", "ON" };
pascal@2866 11
pascal@2866 12 len = strlen (var->name);
pascal@2866 13 memcpy (tbuf, var->name, len);
pascal@2866 14 @@ -909,8 +908,10 @@
pascal@2866 15 *((int *) &prefs + var->offset));
pascal@2866 16 break;
pascal@2866 17 case TYPE_BOOL:
pascal@2866 18 - sprintf (tbuf + len, "\0033:\017 %s\n", offon[
pascal@2866 19 - *((int *) &prefs + var->offset)]);
pascal@2866 20 + if (*((int *) &prefs + var->offset))
pascal@2866 21 + sprintf (tbuf + len, "\0033:\017 %s\n", "ON");
pascal@2866 22 + else
pascal@2866 23 + sprintf (tbuf + len, "\0033:\017 %s\n", "OFF");
pascal@2866 24 break;
pascal@2866 25 }
pascal@2866 26 PrintText (sess, tbuf);
pascal@2866 27 --- xchat-2.8.6/src/common/chanopt.c 2008-06-10 22:00:55.000000000 +1000
pascal@2866 28 +++ xchat-2.8.6p1/src/common/chanopt.c 2008-06-15 13:48:04.000000000 +1000
pascal@2866 29 @@ -32,7 +32,7 @@
pascal@2866 30
pascal@2866 31 #define S_F(xx) STRUCT_OFFSET_STR(struct session,xx)
pascal@2866 32
pascal@2866 33 -channel_options chanopt[] =
pascal@2866 34 +static const channel_options chanopt[] =
pascal@2866 35 {
pascal@2866 36 {"alert_beep", "BEEP", S_F(alert_beep)},
pascal@2866 37 {"alert_taskbar", NULL, S_F(alert_taskbar)},
pascal@2866 38 --- xchat-2.8.6/src/common/servlist.c 2008-04-01 19:22:34.000000000 +1100
pascal@2866 39 +++ xchat-2.8.6p1/src/common/servlist.c 2008-06-15 13:57:41.000000000 +1000
pascal@2866 40 @@ -509,6 +509,8 @@
pascal@2866 41 list = g_slist_nth (net->servlist, net->selected);
pascal@2866 42 if (!list)
pascal@2866 43 list = net->servlist;
pascal@2866 44 + if (!list)
pascal@2866 45 + return;
pascal@2866 46 ircserv = list->data;
pascal@2866 47
pascal@2866 48 /* incase a protocol switch is added to the servlist gui */
pascal@2866 49 --- xchat-2.8.6/src/common/text.c 2008-03-28 13:20:04.000000000 +1100
pascal@2866 50 +++ xchat-2.8.6p1/src/common/text.c 2008-06-15 13:59:59.000000000 +1000
pascal@2866 51 @@ -216,7 +216,7 @@
pascal@2866 52 static void
pascal@2866 53 scrollback_save (session *sess, char *text)
pascal@2866 54 {
pascal@2866 55 - char buf[1024];
pascal@2866 56 + char buf[512 * 4];
pascal@2866 57 time_t stamp;
pascal@2866 58 int len;
pascal@2866 59
pascal@2866 60 @@ -266,7 +266,7 @@
pascal@2866 61 scrollback_load (session *sess)
pascal@2866 62 {
pascal@2866 63 int fh;
pascal@2866 64 - char buf[1024];
pascal@2866 65 + char buf[512 * 4];
pascal@2866 66 char *text;
pascal@2866 67 time_t stamp;
pascal@2866 68 int lines;