By using a semiconductor optical amplifier backward injected with a dark-optical-comb pulse-train at 10 GHz, we demonstrate a 10Gbit/s all-optical non-return-to-zero (NRZ) to return-to-zero (RZ) format conversion of an incoming optical pseudorandom binary sequence (PRBS) data-stream. Without any pre-amplification on the degraded optical NRZ PRBS data, its extinction ratio is greatly improved from 7.13dB to 13.6dB after converting into a RZ PRBS data. To date, the converted RZ PRBS data exhibits a negative power penalty of >3.7 dB at a BER of 10^(-12) in comparison with the NRZ PRBS data.