]> granicus.if.org Git - curl/commitdiff
tool_doswin: Use type SANITIZEcode in sanitize_file_name
authorJay Satiro <raysatiro@yahoo.com>
Fri, 5 Feb 2016 07:22:24 +0000 (02:22 -0500)
committerJay Satiro <raysatiro@yahoo.com>
Fri, 5 Feb 2016 07:22:24 +0000 (02:22 -0500)
src/tool_doswin.c

index 6e1fe0ed3032820a484cda21cfa209a8b2f9b6fa..8650427ca0525c57caebab2cba6939c74c387d65 100644 (file)
@@ -137,7 +137,7 @@ SANITIZEcode sanitize_file_name(char **const sanitized, const char *file_name,
 {
   char *p, *target;
   size_t len;
-  CURLcode res;
+  SANITIZEcode sc;
   size_t max_sanitized_len;
 
   if(!sanitized)
@@ -218,10 +218,10 @@ SANITIZEcode sanitize_file_name(char **const sanitized, const char *file_name,
   }
 
 #ifdef MSDOS
-  res = msdosify(&p, target, flags);
+  sc = msdosify(&p, target, flags);
   free(target);
-  if(res)
-    return res;
+  if(sc)
+    return sc;
   target = p;
   len = strlen(target);
 
@@ -232,10 +232,10 @@ SANITIZEcode sanitize_file_name(char **const sanitized, const char *file_name,
 #endif
 
   if(!(flags & SANITIZE_ALLOW_RESERVED)) {
-    res = rename_if_reserved_dos_device_name(&p, target, flags);
+    sc = rename_if_reserved_dos_device_name(&p, target, flags);
     free(target);
-    if(res)
-      return res;
+    if(sc)
+      return sc;
     target = p;
     len = strlen(target);