Here's what should work:
1 locate the grey system disc which shipped with your Mac.
2 insert the system disc into your optical drive.
3 restart the Mac. Hold the 'C' key down as it restarts. The Mac should boot from the system disk, not from the internal hard drive.
4 select Disk Utility or Utility from the Install menu.
5 repair permissions.
6 fix disk.
7 reboot, this time not holding the 'C' key. The Mac should boot using the internal hard drive.
8 eject the system disc from your optical drive.
9 put the new Snow Leopard disc into the optical drive.
10 if you have not already downloaded the 10.5.8
combo update, do that now.
11 if you have not already made a backup of your
entire internal hard drive, do that now. This backup
must be on a separate hard drive from your internal hard drive, and
must be bootable. I'd use a cheap USB external drive (1 TB USB drives are available for under $80) and either Carbon Copy CLoner or SuperDuper! to make the backup. CCC is donationware and SD! is shareware. There are other disk clone utilities; Drive Genius, for example, includes a disk cloner in its toolkit. I've never used that cloner because I use CCC, but if you have DG and you don't have CCC you don't have to download CCC if you don't want to. Note that CCC, SD!, DG, and other Mac disk cloners will clone the
Mac partition, only. They will not clone the Boot Camp partition. If you want to clone the Boot Camp partition, and you should, you should get hold of a utility such as WinClone, a Mac app which clones Windows partitions, or any of the multitude of Windows disk clone utilities, such as Acronis True Image. Note that if you don't back up your system you may, and probably will, lose data sooner rather than later. There are two kinds of hard disks: the ones which have failed, and the ones which haven't failed yet. They will all fail. All of them.
12 launch and run the 10.5.8 combo updater.
13 reboot, holding the 'C' key. The Mac should start up on the Snow Leopard disc.
14 select Utility from the Install menu.
15 repair permissions.
16 fix disk.
17 select Install from the Install menu.
18 Install Snow Leopard.
19 reboot. The Mac should come up on the internal hard drive, running Snow Leopard.
20 download and install the 10.6.5 update and any other relevant updates.
21 keep the backup in a safe place until you are certain that all is well. If there is a problem, boot up from the backup.
It's not strictly necessary to do
all of the above, but as you were having a problem, this will ensure that you can do things
safely.