Changeset 590 for trunk/src/sh_suidchk.c
- Timestamp:
- Oct 27, 2025, 6:57:03 PM (17 hours ago)
- File:
-
- 1 edited
-
trunk/src/sh_suidchk.c (modified) (13 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_suidchk.c
r583 r590 1019 1019 SL_ENTER(_("sh_suidchk_check_internal")); 1020 1020 1021 if (iname == NULL) 1022 { 1023 TPT((0, FIL__, __LINE__ , _("msg=<directory name is NULL>\n"))); 1024 SL_RETURN( (-1), _("sh_suidchk_check_internal")); 1025 } 1026 1027 if (sig_urgent > 0) { 1028 SL_RETURN( (0), _("sh_suidchk_check_internal")); 1029 } 1030 1021 1031 /* Take the address to keep gcc from putting it into a register. 1022 1032 * Avoids the 'clobbered by longjmp' warning. … … 1024 1034 sh_dummy_idirlist = (void*) &dirlist; 1025 1035 sh_dummy_itmp = (void*) &tmp; 1026 1027 if (iname == NULL)1028 {1029 TPT((0, FIL__, __LINE__ , _("msg=<directory name is NULL>\n")));1030 SL_RETURN( (-1), _("sh_suidchk_check_internal"));1031 }1032 1033 if (sig_urgent > 0) {1034 SL_RETURN( (0), _("sh_suidchk_check_internal"));1035 }1036 1036 1037 1037 thisDir = opendir (iname); … … 1047 1047 SH_MUTEX_UNLOCK(mutex_thread_nolog); 1048 1048 SH_FREE(tmp); 1049 sh_dummy_idirlist = NULL; 1050 sh_dummy_itmp = NULL; 1049 1051 SL_RETURN( (-1), _("sh_suidchk_check_internal")); 1050 1052 } … … 1412 1414 kill_sh_dirlist (dirlist_orig); 1413 1415 1416 sh_dummy_idirlist = NULL; 1417 sh_dummy_itmp = NULL; 1418 1414 1419 SL_RETURN( (0), _("sh_suidchk_check_internal")); 1415 1420 } … … 2193 2198 Return "unknown" if its filesystem type is unknown. */ 2194 2199 2195 static char * 2196 filesystem_type (char * path, char * relpath, struct stat * statp) 2200 static char * filesystem_type (char * path, char * relpath, struct stat * statp) 2197 2201 { 2198 2202 static char *current_fstype = NULL; … … 2218 2222 void * sh_dummy_2229_type; 2219 2223 2220 static char * 2221 filesystem_type_uncached (path, relpath, statp) 2222 char *path; 2223 char *relpath; 2224 struct stat *statp; 2224 static char * filesystem_type_uncached (char * path, char * relpath, struct stat * statp) 2225 2225 { 2226 2226 char * type = NULL; … … 2234 2234 struct mntent *mnt; 2235 2235 2236 if (path == NULL || relpath == NULL) 2237 return NULL; 2238 2236 2239 /* Take the address to keep gcc from putting it into a register. 2237 2240 * Avoids the 'clobbered by longjmp' warning. 2238 2241 */ 2239 2242 sh_dummy_2229_type = (void *) &type; 2240 2241 if (path == NULL || relpath == NULL)2242 return NULL;2243 2243 2244 2244 mfp = setmntent (table, "r"); … … 2250 2250 _("filesystem_type_uncached") ); 2251 2251 SH_MUTEX_UNLOCK(mutex_thread_nolog); 2252 sh_dummy_2229_type = NULL; 2252 2253 return NULL; 2253 2254 } … … 2378 2379 _("filesystem_type_uncached") ); 2379 2380 SH_MUTEX_UNLOCK(mutex_thread_nolog); 2381 sh_dummy_2229_type = NULL; 2380 2382 return NULL; 2381 2383 } … … 2406 2408 _("filesystem_type_uncached") ); 2407 2409 SH_MUTEX_UNLOCK(mutex_thread_nolog); 2410 sh_dummy_2229_type = NULL; 2408 2411 return NULL; 2409 2412 } … … 2453 2456 _("filesystem_type_uncached") ); 2454 2457 SH_MUTEX_UNLOCK(mutex_thread_nolog); 2458 sh_dummy_2229_type = NULL; 2455 2459 return NULL; 2456 2460 } … … 2492 2496 fstype_known = (int)(type != NULL); 2493 2497 2498 sh_dummy_2229_type = NULL; 2494 2499 return sh_util_strdup (type ? type : "unknown"); 2495 2500 } … … 2500 2505 part of CP. */ 2501 2506 2502 static int 2503 xatoi (cp) 2504 const char *cp; 2507 static int xatoi (const char * cp) 2505 2508 { 2506 2509 int val;
Note:
See TracChangeset
for help on using the changeset viewer.