The Australian military suffered a series of defeats during the early months of the Pacific War. The 8th Division and RAAF squadrons in Malaya formed a part of the British Commonwealth forces which were unable to stop a smaller Japanese invasion force which landed on 7 December. The British Commonwealth force withdrew to Singapore at the end of January, but was forced to surrender on 15 February after the Japanese captured much of the island. Smaller Australian forces were also overwhelmed and defeated during early 1942 at Rabaul, and in Ambon, Timor, and Java. The Australian town of Darwin was heavily bombed by the Japanese on 19 February, to prevent it from being used as an Allied base. Over 22,000 Australians were taken prisoner in early 1942 and endured harsh conditions in Japanese captivity. The prisoners were subjected to malnutrition, denied medical treatment and frequently beaten and killed by their guards. As a result, 8,296 Australian prisoners died in captivity.