The command should handle files with embedded newlines, and shouldn't enter into subdirectories as that can be raced.
Normally, something like this could be used:
find /var/crash -mindepth 1 -maxdepth 1 -name '*.uploaded' -type f -size 0 -print0 | xargs -0 rm -rf
Attempting to use the additional sed in there is difficult, and I can't think of a way to do it properly right now.
The command should handle files with embedded newlines, and shouldn't enter into subdirectories as that can be raced.
Normally, something like this could be used:
find /var/crash -mindepth 1 -maxdepth 1 -name '*.uploaded' -type f -size 0 -print0 | xargs -0 rm -rf
Attempting to use the additional sed in there is difficult, and I can't think of a way to do it properly right now.