Changeset 20 for trunk/src/sh_utils.c
- Timestamp:
- Feb 13, 2006, 11:54:42 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_utils.c
r13 r20 51 51 UINT32 ErrFlag[2]; 52 52 53 int sh_util_flagval(c har * c, int * fval)53 int sh_util_flagval(const char * c, int * fval) 54 54 { 55 55 SL_ENTER(_("sh_util_flagval")); … … 101 101 static int sh_ask_update = S_FALSE; 102 102 103 int sh_util_set_interactive(char * str) 104 { 105 if (str == NULL) 106 sh_ask_update = S_TRUE; 107 else 108 sh_ask_update = S_TRUE; 103 int sh_util_set_interactive(const char * str) 104 { 105 (void) str; 106 107 sh_ask_update = S_TRUE; 109 108 110 109 sh_unix_setnodeamon(NULL); … … 950 949 static void copy_four (unsigned char * dest, UINT32 in); 951 950 952 int sh_util_set_newkey (c har * new)951 int sh_util_set_newkey (const char * new_in) 953 952 { 954 953 size_t i, j = 0; … … 964 963 long ii, k = 0; 965 964 UINT32 * h1; 965 char * new; 966 966 967 967 if (0 != sl_is_suid()) … … 973 973 } 974 974 975 if (new == NULL || new[0] == '\0')975 if (new_in == NULL || new_in[0] == '\0') 976 976 { 977 977 fprintf(stderr, … … 981 981 return -1; 982 982 } 983 984 if (NULL == (new = malloc(strlen(new_in) + 1))) 985 goto bail_mem; 986 sl_strncpy(new, new_in, strlen(new_in) + 1); 987 983 988 key = new; 984 989 len = strlen(new); … … 1158 1163 /* server mode 1159 1164 */ 1160 int sh_util_setserver (c har * dummy)1165 int sh_util_setserver (const char * dummy) 1161 1166 { 1162 1167 SL_ENTER(_("sh_util_setserver")); 1163 1168 1164 if (dummy) 1165 sh.flag.isserver = GOOD; 1166 else 1167 sh.flag.isserver = GOOD; 1169 (void) dummy; 1170 sh.flag.isserver = GOOD; 1168 1171 SL_RETURN((0),_("sh_util_setserver")); 1169 1172 } 1170 1173 1171 1174 1172 int sh_util_setlooptime (c har * str)1175 int sh_util_setlooptime (const char * str) 1173 1176 { 1174 1177 int i = atoi (str); … … 1187 1190 1188 1191 #if defined (SH_WITH_CLIENT) || defined (SH_STANDALONE) 1189 int sh_util_setchecksum (c har * str)1192 int sh_util_setchecksum (const char * str) 1190 1193 { 1191 1194 static int reject = 0;
Note:
See TracChangeset
for help on using the changeset viewer.