Fixing Fortran return variables