exec function fixed (windows)