Automator fail with ffmpeg bash line
Automator supplies arguments (file names) to the shell script.
Try:

for f in "$@"
do
    case $f in
        *.m4a)
             /absolute/path/to/ffmpeg -i "$f" -acodec libmp3lame -ab 256k "${f%.m4a}.mp3"
             ;;
    esac
done