summaryrefslogtreecommitdiff
path: root/cygwin
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2017-03-09 13:13:07 -0700
committerKarl Williamson <khw@cpan.org>2017-10-24 08:14:08 -0600
commit083b2a61ee6281f67b6d6a21ad5d27e6219df60f (patch)
tree19277306a3682affdd69bcc12a1e4b1c58306ca0 /cygwin
parent5bad3c4f3a4515aaa622eecdf6f5a84fcaff7ed9 (diff)
downloadperl-083b2a61ee6281f67b6d6a21ad5d27e6219df60f.tar.gz
Convert strcmp into strEQ, strNE
The latter two are easier to read
Diffstat (limited to 'cygwin')
-rw-r--r--cygwin/cygwin.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cygwin/cygwin.c b/cygwin/cygwin.c
index 24b278f2fd..7bcf02ab34 100644
--- a/cygwin/cygwin.c
+++ b/cygwin/cygwin.c
@@ -488,7 +488,7 @@ XS(XS_Cygwin_mount_flags)
pathname = SvPV_nolen(ST(0));
- if (!strcmp(pathname, "/cygdrive")) {
+ if (strEQ(pathname, "/cygdrive")) {
char user[PATH_MAX];
char system[PATH_MAX];
char user_flags[PATH_MAX];
@@ -511,7 +511,7 @@ XS(XS_Cygwin_mount_flags)
int found = 0;
setmntent (0, 0);
while ((mnt = getmntent (0))) {
- if (!strcmp(pathname, mnt->mnt_dir)) {
+ if (strEQ(pathname, mnt->mnt_dir)) {
strcpy(flags, mnt->mnt_type);
if (strlen(mnt->mnt_opts) > 0) {
strcat(flags, ",");
@@ -536,12 +536,12 @@ XS(XS_Cygwin_mount_flags)
user_flags, system_flags);
if (strlen(user) > 0) {
- if (strcmp(user,pathname)) {
+ if (strNE(user,pathname)) {
sprintf(flags, "%s,cygdrive,%s", user_flags, user);
found++;
}
} else {
- if (strcmp(user,pathname)) {
+ if (strNE(user,pathname)) {
sprintf(flags, "%s,cygdrive,%s", system_flags, system);
found++;
}