A comparison of the gamma-ray bursts detected by BATSE and Swift