IIRC a major
asset of Perl back in the day is that it had a _comprehensive_ Unix API,
not just the Platonic ideals of system calls.
Which meant that it was even easier to write a bad and buggy system program in Perl as in C, since Perl had a lower activation barrier in all other matters. Complete with the C feature of ignoring errors unless you made a point of checking them. Even sh has -e.