Their lawyers called expert witnesses who testified that the HIV virus was rampant in the Benghazi hospital where the children were infected before the workers began working there in the late 1990s.
During their retrial last year, the workers said the confessions used by the prosecution had been extracted under torture and named Jumaa al-Mishri, a Libyan police officer, and Abdul-Majid al-Shoul, a doctor.
They said they had been mistreated by several officers including the two men. They later sued, claiming $4m in compensation.
The medics had also denied the defamation charges.
The court did not give any reason for its ruling on Sunday in a short hearing at which the medics were not present.
Georgi Parvanov, the Bulgarian president, described the verdict as a good sign.
The six are due to launch a final appeal against their death sentences shortly.