Jelajahi Sumber

Fix warning: (char)NULL => '\0'

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@40769 15284696-431f-4ddb-bdfa-cd5b030d7da7
Glynn Clements 15 tahun lalu
induk
melakukan
4f1c085d72
1 mengubah file dengan 3 tambahan dan 3 penghapusan
  1. 3 3
      lib/sites/sites.c

+ 3 - 3
lib/sites/sites.c

@@ -930,7 +930,7 @@ int cleanse_string(char *buf)
 	/* but we must skip over escaped */
 	/* (BSLASHed) DQUOTEs */
 	if (*p == DQUOTE) {
-	    while (*p != (char)NULL) {	/* get rid of first DQUOTE */
+	    while (*p != '\0') {	/* get rid of first DQUOTE */
 		*p = *(p + 1);
 		p++;
 	    }
@@ -944,8 +944,8 @@ int cleanse_string(char *buf)
     p = buf;
     while ((p = G_index(p, BSLASH)) != (char *)NULL && p <= stop) {
 	p2 = p + 1;
-	if (*p2 != (char)NULL && (*p2 == DQUOTE || *p2 == BSLASH)) {
-	    while (*p != (char)NULL) {
+	if (*p2 != '\0' && (*p2 == DQUOTE || *p2 == BSLASH)) {
+	    while (*p != '\0') {
 		*p = *(p + 1);
 		p++;
 	    }