summaryrefslogtreecommitdiff
path: root/pp_ctl.c
diff options
context:
space:
mode:
authorHans Mulder <hansmu@xs4all.nl>1998-02-28 10:51:14 -0500
committerMalcolm Beattie <mbeattie@sable.ox.ac.uk>1998-03-05 18:43:57 +0000
commitb6917549c1d9faccceb8c8d200e8d408a1f58a1d (patch)
tree5397db36cc89f086b68973006dc05f0cd171bc39 /pp_ctl.c
parent188cd53ff50c647c5f2128f38b2d4035e11e4770 (diff)
downloadperl-b6917549c1d9faccceb8c8d200e8d408a1f58a1d.tar.gz
print sort {-1} 1..10; hangs
p4raw-id: //depot/perl@773
Diffstat (limited to 'pp_ctl.c')
-rw-r--r--pp_ctl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/pp_ctl.c b/pp_ctl.c
index 9753fcfa76..35915fd602 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -3559,9 +3559,10 @@ qsortsv(
if (j != i) {
/* Looks like we really need to move some things
*/
+ int k;
temp = array[i];
- for (--i; i >= j; --i)
- array[i + 1] = array[i];
+ for (k = i - 1; k >= j; --k)
+ array[k + 1] = array[k];
array[j] = temp;
}
}