Josephson critical current in a long mesoscopic S-N-S junction