summaryrefslogtreecommitdiffhomepage
path: root/mixutils
diff options
context:
space:
mode:
Diffstat (limited to 'mixutils')
-rw-r--r--mixutils/mixvm_loop.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/mixutils/mixvm_loop.c b/mixutils/mixvm_loop.c
index dd37bc6..492ebc6 100644
--- a/mixutils/mixvm_loop.c
+++ b/mixutils/mixvm_loop.c
@@ -1,7 +1,7 @@
/* -*-c-*- -------------- mixvm_loop.c :
* Implementation of mix vm command loop.
* ------------------------------------------------------------------
- * $Id: mixvm_loop.c,v 1.11 2004/06/07 05:05:27 jao Exp $
+ * $Id: mixvm_loop.c,v 1.12 2004/06/07 05:29:42 jao Exp $
* ------------------------------------------------------------------
* Copyright (C) 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
*
@@ -117,10 +117,9 @@ mix_vmloop_set_prompt (const gchar *prompt)
if (prompt)
{
if (PROMPT) g_free (PROMPT);
- if (prompt[0] == '"') prompt++;
- PROMPT = g_strdup (prompt);
+ PROMPT = g_strdup ((prompt[0] == '"') ? prompt + 1 : prompt);
if (PROMPT[strlen (PROMPT) - 1] == '"') PROMPT[strlen (PROMPT) - 1] = 0;
- mix_config_update (config_, PROMPT_KEY_, PROMPT);
+ mix_config_update (config_, PROMPT_KEY_, prompt);
}
}