aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2010-11-21 16:14:03 +0000
committerWilmer van der Gaast <wilmer@gaast.net>2010-11-21 16:14:03 +0000
commit5df65bd866aad7dd7d7b62d7a7ef168a26b002e5 (patch)
tree55d5aa36a7d490c865e9ece46f5e37f5633d2505
parent495d21b4d09392a84ff4c6fd914a0923029d2462 (diff)
Don't save the global "away" settings, leave that to the IRC /AWAY info
coming from the IRC client. Also, hide it from the settings list, it doesn't belong there.
-rw-r--r--protocols/bee.c4
-rw-r--r--set.h1
-rw-r--r--storage_xml.c2
3 files changed, 4 insertions, 3 deletions
diff --git a/protocols/bee.c b/protocols/bee.c
index 81cb7619..5800233d 100644
--- a/protocols/bee.c
+++ b/protocols/bee.c
@@ -33,11 +33,11 @@ bee_t *bee_new()
bee_t *b = g_new0( bee_t, 1 );
set_t *s;
- s = set_add( &b->set, "away", NULL, set_eval_away_status, b );
- s->flags |= SET_NULL_OK;
s = set_add( &b->set, "auto_connect", "true", set_eval_bool, b );
s = set_add( &b->set, "auto_reconnect", "true", set_eval_bool, b );
s = set_add( &b->set, "auto_reconnect_delay", "5*3<900", set_eval_account_reconnect_delay, b );
+ s = set_add( &b->set, "away", NULL, set_eval_away_status, b );
+ s->flags |= SET_NULL_OK | SET_HIDDEN;
s = set_add( &b->set, "debug", "false", set_eval_bool, b );
s = set_add( &b->set, "mobile_is_away", "false", set_eval_bool, b );
s = set_add( &b->set, "save_on_quit", "true", set_eval_bool, b );
diff --git a/set.h b/set.h
index d5be7644..2a8400dd 100644
--- a/set.h
+++ b/set.h
@@ -44,6 +44,7 @@ extern char *SET_INVALID;
typedef enum
{
+ SET_NOSAVE = 0x0001,
SET_NULL_OK = 0x0100,
SET_HIDDEN = 0x0200,
} set_flags_t;
diff --git a/storage_xml.c b/storage_xml.c
index 5035e214..042dcaae 100644
--- a/storage_xml.c
+++ b/storage_xml.c
@@ -493,7 +493,7 @@ static storage_status_t xml_save( irc_t *irc, int overwrite )
g_free( pass_buf );
for( set = irc->b->set; set; set = set->next )
- if( set->value )
+ if( set->value && !( set->flags & SET_NOSAVE ) )
if( !xml_printf( fd, 1, "<setting name=\"%s\">%s</setting>\n", set->key, set->value ) )
goto write_error;
.0.9'>hotfix/0.7.0.9 Unnamed repository; edit this file 'description' to name the repository.MimesBrønn
aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/gems/gettext-2.1.0/test/test_parser.rb
blob: bbbe51fbe0a2b05a84a16ffe34d8b3d6e3c00cdc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158