mirror of
https://github.com/HDFGroup/hdf5.git
synced 2026-09-25 04:09:44 +03:00
Remove HD prefix from toupper/tolower (#4340)
This commit is contained in:
+3
-3
@@ -244,7 +244,7 @@ H5FD_s3comms_hrb_node_set(hrb_node_t **L, const char *name, const char *value)
|
||||
if (lowername == NULL)
|
||||
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "cannot make space for lowercase name copy.");
|
||||
for (i = 0; i < namelen; i++)
|
||||
lowername[i] = (char)HDtolower((int)name[i]);
|
||||
lowername[i] = (char)tolower((int)name[i]);
|
||||
lowername[namelen] = 0;
|
||||
|
||||
/* If value supplied, copy name, value, and concatenated "name: value".
|
||||
@@ -2172,7 +2172,7 @@ H5FD_s3comms_nlowercase(char *dest, const char *s, size_t len)
|
||||
H5MM_memcpy(dest, s, len);
|
||||
do {
|
||||
len--;
|
||||
dest[len] = (char)HDtolower((int)dest[len]);
|
||||
dest[len] = (char)tolower((int)dest[len]);
|
||||
} while (len > 0);
|
||||
}
|
||||
|
||||
@@ -2264,7 +2264,7 @@ H5FD_s3comms_parse_url(const char *str, parsed_url_t **_purl)
|
||||
strncpy(purl->scheme, curstr, (size_t)len);
|
||||
purl->scheme[len] = '\0';
|
||||
for (i = 0; i < len; i++)
|
||||
purl->scheme[i] = (char)HDtolower(purl->scheme[i]);
|
||||
purl->scheme[i] = (char)tolower(purl->scheme[i]);
|
||||
|
||||
/* Skip "://" */
|
||||
tmpstr += 3;
|
||||
|
||||
@@ -893,12 +893,6 @@ H5_DLL H5_ATTR_CONST int Nflock(int fd, int operation);
|
||||
#ifndef HDtmpfile
|
||||
#define HDtmpfile() tmpfile()
|
||||
#endif
|
||||
#ifndef HDtolower
|
||||
#define HDtolower(C) tolower(C)
|
||||
#endif
|
||||
#ifndef HDtoupper
|
||||
#define HDtoupper(C) toupper(C)
|
||||
#endif
|
||||
#ifndef HDunlink
|
||||
#define HDunlink(S) unlink(S)
|
||||
#endif
|
||||
|
||||
+2
-2
@@ -689,7 +689,7 @@ H5_build_extpath(const char *name, char **extpath /*out*/)
|
||||
* Unix: does not apply
|
||||
*/
|
||||
if (H5_CHECK_ABS_DRIVE(name)) {
|
||||
drive = HDtoupper(name[0]) - 'A' + 1;
|
||||
drive = toupper(name[0]) - 'A' + 1;
|
||||
retcwd = HDgetdcwd(drive, cwdpath, MAX_PATH_LEN);
|
||||
strncpy(new_name, &name[2], name_len);
|
||||
}
|
||||
@@ -1404,7 +1404,7 @@ H5_strcasestr(const char *haystack, const char *needle)
|
||||
const char *h = haystack;
|
||||
const char *n = needle;
|
||||
/* loop while lowercase strings match, or needle ends */
|
||||
while (HDtolower(*h) == HDtolower(*n) && *n) {
|
||||
while (tolower(*h) == tolower(*n) && *n) {
|
||||
h++;
|
||||
n++;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user