An optimized fast pulse-shape discrimination algorithm is used to discriminate neutrons from gamma rays with high accuracy, in a mixed radiation field. The discriminated data is subsequently used to identify the source. Experimental pulse-height distributions from discriminated data are shown for Cf-252 and Am-Be sources and are compared with simulations performed with the MCNP-PoliMi code. In all cases, very good agreement between simulations and measurements was achieved. In addition, several source-shielding configurations are presented to assess the influence of the potential source shielding on the measured neutron pulse-height distribution.