Revert "Imported Upstream version 7.53.1"
[platform/upstream/curl.git] / lib / curl_endian.c
index 14a2883..76deca6 100644 (file)
@@ -9,7 +9,7 @@
  *
  * This software is licensed as described in the file COPYING, which
  * you should have received as part of this distribution. The terms
- * are also available at http://curl.haxx.se/docs/copyright.html.
+ * are also available at https://curl.haxx.se/docs/copyright.html.
  *
  * You may opt to use, copy, modify, merge, publish, distribute and/or sell
  * copies of the Software, and permit persons to whom the Software is
@@ -62,6 +62,7 @@ unsigned int Curl_read32_le(unsigned char *buf)
          ((unsigned int)buf[2] << 16) | ((unsigned int)buf[3] << 24);
 }
 
+#if (CURL_SIZEOF_CURL_OFF_T > 4)
 /*
  * Curl_read64_le()
  *
@@ -97,6 +98,8 @@ unsigned __int64 Curl_read64_le(unsigned char *buf)
 }
 #endif
 
+#endif /* CURL_SIZEOF_CURL_OFF_T > 4 */
+
 /*
  * Curl_read16_be()
  *
@@ -135,6 +138,7 @@ unsigned int Curl_read32_be(unsigned char *buf)
          ((unsigned int)buf[2] << 8) | ((unsigned int)buf[3]);
 }
 
+#if (CURL_SIZEOF_CURL_OFF_T > 4)
 /*
  * Curl_read64_be()
  *
@@ -170,6 +174,8 @@ unsigned __int64 Curl_read64_be(unsigned char *buf)
 }
 #endif
 
+#endif /* CURL_SIZEOF_CURL_OFF_T > 4 */
+
 /*
  * Curl_write16_le()
  *
@@ -227,4 +233,4 @@ void Curl_write64_le(const __int64 value, unsigned char *buffer)
   Curl_write32_le((int)value, buffer);
   Curl_write32_le((int)(value >> 32), buffer + 4);
 }
-#endif
+#endif /* CURL_SIZEOF_CURL_OFF_T > 4 */