setuid and setgid shell scripts refuse to run. They return an error message similar to /dev/fd/3: /dev/fd/3: cannot open. (The number following /dev/fd/ is not necessarily 3.) The first line of the script properly starts a shell, and the file system containing the script is not mounted with the nosuid option.
Running truss on the shell script reveals that a call to open(2) is failing with error number 6 (ENXIO):
open("/dev/fd/3", O_RDONLY) Err#6 ENXIO