You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
strcat(NULL, x); // expected-warning{{Null pointer argument in call to string copy function}}
427
+
strcat(NULL, x); // expected-warning{{Null pointer passed as 1st argument to string concatenation function}}
428
428
}
429
429
430
430
voidstrcat_null_src(char*x) {
431
-
strcat(x, NULL); // expected-warning{{Null pointer argument in call to string copy function}}
431
+
strcat(x, NULL); // expected-warning{{Null pointer passed as 2nd argument to string concatenation function}}
432
432
}
433
433
434
434
voidstrcat_fn(char*x) {
435
-
strcat(x, (char*)&strcat_fn); // expected-warning{{Argument to string copy function is the address of the function 'strcat_fn', which is not a null-terminated string}}
435
+
strcat(x, (char*)&strcat_fn); // expected-warning{{Argument to string concatenation function is the address of the function 'strcat_fn', which is not a null-terminated string}}
strncat(NULL, x, 4); // expected-warning{{Null pointer argument in call to string copy function}}
634
+
strncat(NULL, x, 4); // expected-warning{{Null pointer passed as 1st argument to string concatenation function}}
635
635
}
636
636
637
637
voidstrncat_null_src(char*x) {
638
-
strncat(x, NULL, 4); // expected-warning{{Null pointer argument in call to string copy function}}
638
+
strncat(x, NULL, 4); // expected-warning{{Null pointer passed as 2nd argument to string concatenation function}}
639
639
}
640
640
641
641
voidstrncat_fn(char*x) {
642
-
strncat(x, (char*)&strncat_fn, 4); // expected-warning{{Argument to string copy function is the address of the function 'strncat_fn', which is not a null-terminated string}}
642
+
strncat(x, (char*)&strncat_fn, 4); // expected-warning{{Argument to string concatenation function is the address of the function 'strncat_fn', which is not a null-terminated string}}
643
643
}
644
644
645
645
voidstrncat_effects(char*y) {
@@ -812,13 +812,13 @@ void strcmp_2() {
812
812
voidstrcmp_null_0() {
813
813
char*x=NULL;
814
814
char*y="123";
815
-
strcmp(x, y); // expected-warning{{Null pointer argument in call to string comparison function}}
815
+
strcmp(x, y); // expected-warning{{Null pointer passed as 1st argument to string comparison function}}
816
816
}
817
817
818
818
voidstrcmp_null_1() {
819
819
char*x="123";
820
820
char*y=NULL;
821
-
strcmp(x, y); // expected-warning{{Null pointer argument in call to string comparison function}}
821
+
strcmp(x, y); // expected-warning{{Null pointer passed as 2nd argument to string comparison function}}
822
822
}
823
823
824
824
voidstrcmp_diff_length_0() {
@@ -921,13 +921,13 @@ void strncmp_2() {
921
921
voidstrncmp_null_0() {
922
922
char*x=NULL;
923
923
char*y="123";
924
-
strncmp(x, y, 3); // expected-warning{{Null pointer argument in call to string comparison function}}
924
+
strncmp(x, y, 3); // expected-warning{{Null pointer passed as 1st argument to string comparison function}}
925
925
}
926
926
927
927
voidstrncmp_null_1() {
928
928
char*x="123";
929
929
char*y=NULL;
930
-
strncmp(x, y, 3); // expected-warning{{Null pointer argument in call to string comparison function}}
930
+
strncmp(x, y, 3); // expected-warning{{Null pointer passed as 2nd argument to string comparison function}}
931
931
}
932
932
933
933
voidstrncmp_diff_length_0() {
@@ -1030,13 +1030,13 @@ void strcasecmp_2() {
1030
1030
voidstrcasecmp_null_0() {
1031
1031
char*x=NULL;
1032
1032
char*y="123";
1033
-
strcasecmp(x, y); // expected-warning{{Null pointer argument in call to string comparison function}}
1033
+
strcasecmp(x, y); // expected-warning{{Null pointer passed as 1st argument to string comparison function}}
1034
1034
}
1035
1035
1036
1036
voidstrcasecmp_null_1() {
1037
1037
char*x="123";
1038
1038
char*y=NULL;
1039
-
strcasecmp(x, y); // expected-warning{{Null pointer argument in call to string comparison function}}
1039
+
strcasecmp(x, y); // expected-warning{{Null pointer passed as 2nd argument to string comparison function}}
1040
1040
}
1041
1041
1042
1042
voidstrcasecmp_diff_length_0() {
@@ -1121,13 +1121,13 @@ void strncasecmp_2() {
1121
1121
voidstrncasecmp_null_0() {
1122
1122
char*x=NULL;
1123
1123
char*y="123";
1124
-
strncasecmp(x, y, 3); // expected-warning{{Null pointer argument in call to string comparison function}}
1124
+
strncasecmp(x, y, 3); // expected-warning{{Null pointer passed as 1st argument to string comparison function}}
1125
1125
}
1126
1126
1127
1127
voidstrncasecmp_null_1() {
1128
1128
char*x="123";
1129
1129
char*y=NULL;
1130
-
strncasecmp(x, y, 3); // expected-warning{{Null pointer argument in call to string comparison function}}
1130
+
strncasecmp(x, y, 3); // expected-warning{{Null pointer passed as 2nd argument to string comparison function}}
0 commit comments