Add one more "escape" for marking internal variables.

This commit is contained in:
Jordan K. Hubbard 1999-02-05 22:25:13 +00:00
parent 6f8126face
commit b1e7bed4c0
6 changed files with 24 additions and 24 deletions

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated for what's essentially a complete rewrite.
*
* $Id: dmenu.c,v 1.37 1998/03/15 19:30:46 jkh Exp $
* $Id: dmenu.c,v 1.38 1999/02/05 22:15:48 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -88,7 +88,7 @@ dmenuExit(dialogMenuItem *tmp)
int
dmenuSetVariable(dialogMenuItem *tmp)
{
variable_set((char *)tmp->data, 1);
variable_set((char *)tmp->data, *tmp != '_');
return DITEM_SUCCESS;
}
@ -101,7 +101,7 @@ dmenuSetVariables(dialogMenuItem *tmp)
for (cp1 = copy; cp1 != NULL;) {
cp2 = index(cp1, ',');
if (cp2 != NULL) *cp2++ = '\0';
variable_set(cp1, 1);
variable_set(cp1, *cp1 != '_');
cp1 = cp2;
}
free(copy);
@ -137,7 +137,7 @@ dmenuToggleVariable(dialogMenuItem *tmp)
return DITEM_FAILURE;
}
if (!variable_check(var))
variable_set(var, 1);
variable_set(var, *var != '_');
else
variable_unset(var);
return DITEM_SUCCESS;
@ -161,7 +161,7 @@ dmenuISetVariable(dialogMenuItem *tmp)
else if (!*ans)
variable_unset(var);
else
variable_set2(var, ans, 1);
variable_set2(var, ans, *var != '_');
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.155 1999/02/02 15:57:13 jkh Exp $
* $Id: sysinstall.h,v 1.156 1999/02/05 22:15:51 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -104,7 +104,7 @@
#define VAR_CONFIG_FILE "configFile"
#define VAR_FTP_DIR "ftpDirectory"
#define VAR_FTP_PASS "ftpPass"
#define VAR_FTP_PATH "ftp"
#define VAR_FTP_PATH "_ftpPath"
#define VAR_FTP_PORT "ftpPort"
#define VAR_FTP_STATE "ftpState"
#define VAR_FTP_USER "ftpUser"
@ -159,7 +159,7 @@
#define VAR_UFS_PATH "ufs"
#define VAR_USR_SIZE "usrSize"
#define VAR_VAR_SIZE "varSize"
#define VAR_XF86_CONFIG "xf86config"
#define VAR_XF86_CONFIG "_xf86config"
#define DEFAULT_TAPE_BLOCKSIZE "20"

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated for what's essentially a complete rewrite.
*
* $Id: dmenu.c,v 1.37 1998/03/15 19:30:46 jkh Exp $
* $Id: dmenu.c,v 1.38 1999/02/05 22:15:48 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -88,7 +88,7 @@ dmenuExit(dialogMenuItem *tmp)
int
dmenuSetVariable(dialogMenuItem *tmp)
{
variable_set((char *)tmp->data, 1);
variable_set((char *)tmp->data, *tmp != '_');
return DITEM_SUCCESS;
}
@ -101,7 +101,7 @@ dmenuSetVariables(dialogMenuItem *tmp)
for (cp1 = copy; cp1 != NULL;) {
cp2 = index(cp1, ',');
if (cp2 != NULL) *cp2++ = '\0';
variable_set(cp1, 1);
variable_set(cp1, *cp1 != '_');
cp1 = cp2;
}
free(copy);
@ -137,7 +137,7 @@ dmenuToggleVariable(dialogMenuItem *tmp)
return DITEM_FAILURE;
}
if (!variable_check(var))
variable_set(var, 1);
variable_set(var, *var != '_');
else
variable_unset(var);
return DITEM_SUCCESS;
@ -161,7 +161,7 @@ dmenuISetVariable(dialogMenuItem *tmp)
else if (!*ans)
variable_unset(var);
else
variable_set2(var, ans, 1);
variable_set2(var, ans, *var != '_');
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.155 1999/02/02 15:57:13 jkh Exp $
* $Id: sysinstall.h,v 1.156 1999/02/05 22:15:51 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -104,7 +104,7 @@
#define VAR_CONFIG_FILE "configFile"
#define VAR_FTP_DIR "ftpDirectory"
#define VAR_FTP_PASS "ftpPass"
#define VAR_FTP_PATH "ftp"
#define VAR_FTP_PATH "_ftpPath"
#define VAR_FTP_PORT "ftpPort"
#define VAR_FTP_STATE "ftpState"
#define VAR_FTP_USER "ftpUser"
@ -159,7 +159,7 @@
#define VAR_UFS_PATH "ufs"
#define VAR_USR_SIZE "usrSize"
#define VAR_VAR_SIZE "varSize"
#define VAR_XF86_CONFIG "xf86config"
#define VAR_XF86_CONFIG "_xf86config"
#define DEFAULT_TAPE_BLOCKSIZE "20"

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated for what's essentially a complete rewrite.
*
* $Id: dmenu.c,v 1.37 1998/03/15 19:30:46 jkh Exp $
* $Id: dmenu.c,v 1.38 1999/02/05 22:15:48 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -88,7 +88,7 @@ dmenuExit(dialogMenuItem *tmp)
int
dmenuSetVariable(dialogMenuItem *tmp)
{
variable_set((char *)tmp->data, 1);
variable_set((char *)tmp->data, *tmp != '_');
return DITEM_SUCCESS;
}
@ -101,7 +101,7 @@ dmenuSetVariables(dialogMenuItem *tmp)
for (cp1 = copy; cp1 != NULL;) {
cp2 = index(cp1, ',');
if (cp2 != NULL) *cp2++ = '\0';
variable_set(cp1, 1);
variable_set(cp1, *cp1 != '_');
cp1 = cp2;
}
free(copy);
@ -137,7 +137,7 @@ dmenuToggleVariable(dialogMenuItem *tmp)
return DITEM_FAILURE;
}
if (!variable_check(var))
variable_set(var, 1);
variable_set(var, *var != '_');
else
variable_unset(var);
return DITEM_SUCCESS;
@ -161,7 +161,7 @@ dmenuISetVariable(dialogMenuItem *tmp)
else if (!*ans)
variable_unset(var);
else
variable_set2(var, ans, 1);
variable_set2(var, ans, *var != '_');
return DITEM_SUCCESS;
}

View File

@ -4,7 +4,7 @@
* This is probably the last attempt in the `sysinstall' line, the next
* generation being slated to essentially a complete rewrite.
*
* $Id: sysinstall.h,v 1.155 1999/02/02 15:57:13 jkh Exp $
* $Id: sysinstall.h,v 1.156 1999/02/05 22:15:51 jkh Exp $
*
* Copyright (c) 1995
* Jordan Hubbard. All rights reserved.
@ -104,7 +104,7 @@
#define VAR_CONFIG_FILE "configFile"
#define VAR_FTP_DIR "ftpDirectory"
#define VAR_FTP_PASS "ftpPass"
#define VAR_FTP_PATH "ftp"
#define VAR_FTP_PATH "_ftpPath"
#define VAR_FTP_PORT "ftpPort"
#define VAR_FTP_STATE "ftpState"
#define VAR_FTP_USER "ftpUser"
@ -159,7 +159,7 @@
#define VAR_UFS_PATH "ufs"
#define VAR_USR_SIZE "usrSize"
#define VAR_VAR_SIZE "varSize"
#define VAR_XF86_CONFIG "xf86config"
#define VAR_XF86_CONFIG "_xf86config"
#define DEFAULT_TAPE_BLOCKSIZE "20"