diff options
| author | Wilmer van der Gaast <wilmer@gaast.net> | 2013-10-14 09:02:04 -0700 | 
|---|---|---|
| committer | Wilmer van der Gaast <wilmer@gaast.net> | 2013-10-14 09:02:04 -0700 | 
| commit | d4a4f1a076eea0bb50ab30fda5323328dd8df568 (patch) | |
| tree | 68e535d45ac96761a235d4be48dfdacc9da8fe0f /irc_channel.c | |
| parent | a685409f7e5587fa123b380775afd1586d938358 (diff) | |
Don't save the "type" channel setting, it's an XML attribute already. This
fix is ugly as it's putting a detail relevant to XML storage elsewhere in
the code. But I don't think we should have any other storage formats anyway.
Diffstat (limited to 'irc_channel.c')
| -rw-r--r-- | irc_channel.c | 5 | 
1 files changed, 4 insertions, 1 deletions
| diff --git a/irc_channel.c b/irc_channel.c index 4e8c0bb5..88aecce6 100644 --- a/irc_channel.c +++ b/irc_channel.c @@ -34,6 +34,7 @@ extern const struct irc_channel_funcs irc_channel_im_chat_funcs;  irc_channel_t *irc_channel_new( irc_t *irc, const char *name )  {  	irc_channel_t *ic; +	set_t *s;  	if( !irc_channel_name_ok( name ) || irc_channel_by_name( irc, name ) )  		return NULL; @@ -48,7 +49,9 @@ irc_channel_t *irc_channel_new( irc_t *irc, const char *name )  	irc->channels = g_slist_append( irc->channels, ic );  	set_add( &ic->set, "auto_join", "false", set_eval_bool, ic ); -	set_add( &ic->set, "type", "control", set_eval_channel_type, ic ); +	 +	s = set_add( &ic->set, "type", "control", set_eval_channel_type, ic ); +	s->flags |= SET_NOSAVE;    /* Layer violation (XML format detail) */  	if( name[0] == '&' )  		set_setstr( &ic->set, "type", "control" ); | 
