From f55ac4a45513e50ae06769ee748ea079c9577a7f Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Thu, 9 Mar 2017 10:55:38 -0700 Subject: Change some strncmp(), etc. to strBEGINs() The latter is much clearer as to what's going on, and the programmer and program reader don't have to count characters. --- ext/VMS-Stdio/Stdio.pm | 2 +- ext/VMS-Stdio/Stdio.xs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'ext/VMS-Stdio') diff --git a/ext/VMS-Stdio/Stdio.pm b/ext/VMS-Stdio/Stdio.pm index f9ed211d3b..e692e05b08 100644 --- a/ext/VMS-Stdio/Stdio.pm +++ b/ext/VMS-Stdio/Stdio.pm @@ -13,7 +13,7 @@ use Carp '&croak'; use DynaLoader (); use Exporter (); -$VERSION = '2.42'; +$VERSION = '2.43'; @ISA = qw( Exporter DynaLoader IO::File ); @EXPORT = qw( &O_APPEND &O_CREAT &O_EXCL &O_NDELAY &O_NOWAIT &O_RDONLY &O_RDWR &O_TRUNC &O_WRONLY ); diff --git a/ext/VMS-Stdio/Stdio.xs b/ext/VMS-Stdio/Stdio.xs index 144f9370cc..1e96cdb9c6 100644 --- a/ext/VMS-Stdio/Stdio.xs +++ b/ext/VMS-Stdio/Stdio.xs @@ -15,7 +15,7 @@ static bool constant(char *name, IV *pval) { - if (strnNE(name, "O_", 2)) return FALSE; + if (! strBEGINs(name, "O_")) return FALSE; if (strEQ(name, "O_APPEND")) #ifdef O_APPEND -- cgit v1.2.1