Skip to content

Commit d30de6d

Browse files
committed
vcardcomponent.c: silence Windows compiler complaints
1 parent 7651624 commit d30de6d

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/libicalvcard/vcardcomponent.c

+4-5
Original file line numberDiff line numberDiff line change
@@ -942,7 +942,7 @@ static void comp_to_v4(vcardcomponent *impl)
942942
buf_ptr = mediatype + size;
943943
icalmemory_append_string(&mediatype, &buf_ptr,
944944
&size, type->xvalue);
945-
for (char *c = mediatype; (*c = tolower(*c)); c++);
945+
for (char *c = mediatype; (*c = (char) tolower(*c)); c++);
946946

947947
/* Remove this TYPE */
948948
vcardenumarray_remove_element_at(types, i);
@@ -1070,7 +1070,7 @@ static void comp_to_v3(vcardcomponent *impl)
10701070
if ((subtype = strchr(mediatype, '/'))) {
10711071
/* Copy and uppercase the subtype */
10721072
subtype = icalmemory_strdup(subtype + 1);
1073-
for (char *c = subtype; (*c = toupper(*c)); c++);
1073+
for (char *c = subtype; (*c = (char) toupper(*c)); c++);
10741074

10751075
/* Add TYPE parameter */
10761076
vcardenumarray_element type = { .xvalue = subtype };
@@ -1123,8 +1123,7 @@ static void comp_to_v3(vcardcomponent *impl)
11231123
base64 = strstr(mediatype, ";base64,");
11241124

11251125
if (base64) {
1126-
vcardparameter *param =
1127-
vcardparameter_new_encoding(VCARD_ENCODING_B);
1126+
param = vcardparameter_new_encoding(VCARD_ENCODING_B);
11281127
vcardproperty_add_parameter(prop, param);
11291128

11301129
*base64 = '\0';
@@ -1136,7 +1135,7 @@ static void comp_to_v3(vcardcomponent *impl)
11361135

11371136
if ((subtype = strchr(mediatype, '/'))) {
11381137
/* Copy and uppercase the subtype */
1139-
for (char *c = ++subtype; (*c = toupper(*c)); c++);
1138+
for (char *c = ++subtype; (*c = (char) toupper(*c)); c++);
11401139

11411140
/* Add TYPE parameter */
11421141
vcardenumarray_element type = { .xvalue = subtype };

0 commit comments

Comments
 (0)