Trying to trap signal SIGXFSZ when applying ulimit -f in script my attempts:
script:
#! /bin/bash
function catch_SIGXFSZ {
echo "caught!!"
}
echo running
ulimit -f 1
trap catch_SIGXFSZ 25
cat bigtmp.log > tmp.log
echo after
after running i get:
./try.sh
running
File size limit exceeded
after
any idea why the trap isn't working? thanks for the help!