Index: account.c
===================================================================
--- account.c	(revision 7125cb3775a0e384c0f2fc08fd56df9582199502)
+++ account.c	(revision f3579fd061746fe88c53330a2b9002da4193b37a)
@@ -55,5 +55,5 @@
 	
 	s = set_add( &a->set, "password", NULL, set_eval_account, a );
-	s->flags |= ACC_SET_NOSAVE;
+	s->flags |= ACC_SET_NOSAVE | SET_NULL_OK;
 	
 	s = set_add( &a->set, "username", NULL, set_eval_account, a );
Index: irc.c
===================================================================
--- irc.c	(revision 7125cb3775a0e384c0f2fc08fd56df9582199502)
+++ irc.c	(revision f3579fd061746fe88c53330a2b9002da4193b37a)
@@ -34,11 +34,17 @@
 GSList *irc_connection_list = NULL;
 
-static char *passchange( set_t *set, char *value )
+static char *set_eval_password( set_t *set, char *value )
 {
 	irc_t *irc = set->data;
 	
-	irc_setpass( irc, value );
-	irc_usermsg( irc, "Password successfully changed" );
-	return NULL;
+	if( irc->status & USTATUS_IDENTIFIED )
+	{
+		irc_setpass( irc, value );
+		return NULL;
+	}
+	else
+	{
+		return SET_INVALID;
+	}
 }
 
@@ -150,5 +156,5 @@
 	s = set_add( &irc->set, "lcnicks", "true", set_eval_bool, irc );
 	s = set_add( &irc->set, "ops", "both", set_eval_ops, irc );
-	s = set_add( &irc->set, "password", NULL, passchange, irc );
+	s = set_add( &irc->set, "password", NULL, set_eval_password, irc );
 	s->flags |= SET_NULL_OK;
 	s = set_add( &irc->set, "private", "true", set_eval_bool, irc );
Index: root_commands.c
===================================================================
--- root_commands.c	(revision 7125cb3775a0e384c0f2fc08fd56df9582199502)
+++ root_commands.c	(revision f3579fd061746fe88c53330a2b9002da4193b37a)
@@ -238,4 +238,14 @@
 }
 
+static void cmd_showset( irc_t *irc, set_t *set )
+{
+	char *s;
+	
+	if( set && ( s = set_getstr( &set, set->key ) ) ) /* HACK! */
+		irc_usermsg( irc, "%s = `%s'", set->key, s );
+	else
+		irc_usermsg( irc, "%s is empty", set->key );
+}
+
 static void cmd_account( irc_t *irc, char **cmd )
 {
@@ -445,4 +455,5 @@
 		{
 			set_t *s = set_find( &a->set, set_name );
+			int st;
 			
 			if( a->ic && s && s->flags & ACC_SET_OFFLINE_ONLY )
@@ -460,15 +471,23 @@
 			
 			if( g_strncasecmp( cmd[2], "-del", 4 ) == 0 )
-				set_reset( &a->set, set_name );
+				st = set_reset( &a->set, set_name );
 			else
-				set_setstr( &a->set, set_name, cmd[3] );
-		}
-		if( set_name ) /* else 'forgotten' on purpose.. Must show new value after changing */
-		{
-			char *s = set_getstr( &a->set, set_name );
-			if( s )
-				irc_usermsg( irc, "%s = `%s'", set_name, s );
+				st = set_setstr( &a->set, set_name, cmd[3] );
+			
+			if( set_getstr( &a->set, set_name ) == NULL )
+			{
+				if( st )
+					irc_usermsg( irc, "Setting changed successfully" );
+				else
+					irc_usermsg( irc, "Failed to change setting" );
+			}
 			else
-				irc_usermsg( irc, "%s is empty", set_name );
+			{
+				cmd_showset( irc, set_find( &a->set, set_name ) );
+			}
+		}
+		else if( set_name )
+		{
+			cmd_showset( irc, set_find( &a->set, set_name ) );
 		}
 		else
@@ -477,8 +496,5 @@
 			while( s )
 			{
-				if( s->value || s->def )
-					irc_usermsg( irc, "%s = `%s'", s->key, s->value ? s->value : s->def );
-				else
-					irc_usermsg( irc, "%s is empty", s->key );
+				cmd_showset( irc, s );
 				s = s->next;
 			}
@@ -823,21 +839,35 @@
 	if( cmd[1] && cmd[2] )
 	{
+		int st;
+		
 		if( g_strncasecmp( cmd[1], "-del", 4 ) == 0 )
 		{
-			set_reset( &irc->set, cmd[2] );
+			st = set_reset( &irc->set, cmd[2] );
 			set_name = cmd[2];
 		}
 		else
 		{
-			set_setstr( &irc->set, cmd[1], cmd[2] );
-		}
-	}
-	if( set_name ) /* else 'forgotten' on purpose.. Must show new value after changing */
-	{
-		char *s = set_getstr( &irc->set, set_name );
- 		if( s )
-			irc_usermsg( irc, "%s = `%s'", set_name, s );
-		else
-			irc_usermsg( irc, "%s is empty", set_name );
+			st = set_setstr( &irc->set, cmd[1], cmd[2] );
+		}
+		
+		/* Normally we just show the variable's new/unchanged
+		   value as feedback to the user, but this has always
+		   caused confusion when changing the password. Give
+		   other feedback instead: */
+		if( set_getstr( &irc->set, set_name ) == NULL )
+		{
+			if( st )
+				irc_usermsg( irc, "Setting changed successfully" );
+			else
+				irc_usermsg( irc, "Failed to change setting" );
+		}
+		else
+		{
+			cmd_showset( irc, set_find( &irc->set, set_name ) );
+		}
+	}
+	else if( set_name )
+	{
+		cmd_showset( irc, set_find( &irc->set, set_name ) );
 
 		if( strchr( set_name, '/' ) )
@@ -849,8 +879,5 @@
 		while( s )
 		{
-			if( s->value || s->def )
-				irc_usermsg( irc, "%s = `%s'", s->key, s->value ? s->value : s->def );
-			else
-				irc_usermsg( irc, "%s is empty", s->key );
+			cmd_showset( irc, s );
 			s = s->next;
 		}
Index: set.c
===================================================================
--- set.c	(revision 7125cb3775a0e384c0f2fc08fd56df9582199502)
+++ set.c	(revision f3579fd061746fe88c53330a2b9002da4193b37a)
@@ -182,5 +182,5 @@
 }
 
-void set_reset( set_t **head, char *key )
+int set_reset( set_t **head, char *key )
 {
 	set_t *s;
@@ -188,5 +188,7 @@
 	s = set_find( head, key );
 	if( s )
-		set_setstr( head, key, s->def );
+		return set_setstr( head, key, s->def );
+	
+	return 0;
 }
 
Index: set.h
===================================================================
--- set.h	(revision 7125cb3775a0e384c0f2fc08fd56df9582199502)
+++ set.h	(revision f3579fd061746fe88c53330a2b9002da4193b37a)
@@ -92,5 +92,5 @@
 int set_setint( set_t **head, char *key, int value );
 void set_del( set_t **head, char *key );
-void set_reset( set_t **head, char *key );
+int set_reset( set_t **head, char *key );
 
 /* Two very useful generic evaluators. */
