diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 1999-05-14 04:22:48 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 1999-05-14 04:22:48 +0000 |
commit | 6df5fd6690ead2545a5712eae33a0298ed60f85a (patch) | |
tree | cbc88a7d57cb66c9a2731c3504e6a321696ac393 | |
parent | ee4a5420505bd1a8c7d4737cf4ba37d160320d81 (diff) |
Need to check for the c suffix on args to the -size switch. Patch sent to perl maintainers.
-rw-r--r-- | gnu/usr.bin/perl/x2p/find2perl.PL | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gnu/usr.bin/perl/x2p/find2perl.PL b/gnu/usr.bin/perl/x2p/find2perl.PL index f82b6602e72..cbb32fdb65e 100644 --- a/gnu/usr.bin/perl/x2p/find2perl.PL +++ b/gnu/usr.bin/perl/x2p/find2perl.PL @@ -140,7 +140,12 @@ while (@ARGV) { $out .= &tab . '($ino ' . &n(shift); } elsif ($_ eq 'size') { - $out .= &tab . '(int(((-s _) + 511) / 512) ' . &n(shift); + $_ = shift; + if (s/c$//) { + $out .= &tab . '(int(-s _) ' . &n($_); + } else { + $out .= &tab . '(int(((-s _) + 511) / 512) ' . &n($_); + } } elsif ($_ eq 'atime') { $out .= &tab . '(int(-A _) ' . &n(shift); |