summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2005-11-08 21:37:52 +0000
committerNicholas Clark <nick@ccl4.org>2005-11-08 21:37:52 +0000
commit42d9b98d3f03094883cfc4bb765785a6d4396077 (patch)
treecb639739736f31b4c4068d5e3c9eb09b306d89fd /op.c
parentf7997f866fdcafc687fbaa99dbeb48f109b2e8d8 (diff)
downloadperl-42d9b98d3f03094883cfc4bb765785a6d4396077.tar.gz
Eliminate some unnecessary strlen()s
p4raw-id: //depot/perl@26050
Diffstat (limited to 'op.c')
-rw-r--r--op.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/op.c b/op.c
index 2eefa1d1eb..2ca186c2b5 100644
--- a/op.c
+++ b/op.c
@@ -5940,8 +5940,9 @@ Perl_ck_require(pTHX_ OP *o)
for (s = SvPVX(sv); *s; s++) {
if (*s == ':' && s[1] == ':') {
+ const STRLEN len = strlen(s+2)+1;
*s = '/';
- Move(s+2, s+1, strlen(s+2)+1, char);
+ Move(s+2, s+1, len, char);
SvCUR_set(sv, SvCUR(sv) - 1);
}
}