Replacing system files

I was recently asked to review a TV capture card with onboard tuner, a task that seemed easy enough. However, despite installing the card correctly and ensuring that there were no hardware conflicts, nothing could be seen or heard. Not only did the card not work, but Windows Movie Maker hung, as well. It was one of those frustrating problems that took a long time and lots of effort to solve, because Windows doesn’t give you any hints as to what’s going wrong: is it the driver for the TV tuner, the video card, or some other part of the operating system that has indigestion?

Eventually, I traced it down to Microsoft’s DirectX 9.0b update by trying out the card in different Windows XP Professional installations with and without the patch. I discovered that OS installations updated up to DirectX 9.0a worked fine with the card, but beyond that, no go. As DirectX 9.0b contains performance and security enhancements, it seems like a good thing to have, so I decided to pinpoint the cause of the problem.

I told Windows XP Professional to run the built-in debugger, Dr Watson (drwtsn32.exe) (see FIGURE 1), automatically, by firing up regedit and changing the following Registry entry to 1 (one) :HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\AeDebug\Auto

see FIGURE 2 for an image

The next time the TV tuner application crashed, I could wade through the information in the log file created by Dr Watson. Each time around, the good Doc fingered the kstvtune.ax file in the %windir%\System32 directory. This little file was updated to version 5.3.1.902 through DirectX 9.0b, and is described as a ‘WDM [Windows Driver Model] Streaming TVTuner’; it is a DirectShow Filter responsible for tuning into the different channels the card can receive. No wonder no channels showed up! Microsoft’s DirectX team has confirmed that the updated file is causing problems with PAL TV tuner cards.

I thought about backing out of the 9.0b update and reverting to 9.0a, and wait for Microsoft to come out with a less broken patch, but… I had turned off System Restore for benchmark testing, and as we all know, once installed, DirectX 9 isn’t easily removed from Windows XP.

As it was just a single file causing the problem and I really didn’t want to reinstall Windows, it was Quick-And-Dirty Hack Time. Well, it wasn’t exactly a quick hack, but it fixed the TV tuner and Movie Maker issues. The tools required were:

  • DirectX 9.0a runtime (no longer on Microsoft’s Web site, available on the September cover CD)
  • WinRAR (www.rarsoft.com or on this month’s cover CD)
  • CabPack 1.4 (http://home.t-online.de/home/lars.hederer or your favourite Win32 Freeware file site)

First, I extracted the kstvtune.ax file (version 5.3.0.900) from the DirectX 9.0a runtime, with the help of WinRAR, and saved it on the hard disk. Next, I searched for all newer instances of kstvtune.ax on the system. Thanks to Windows File Protection, which protects the operating system against accidental deletions and overwrites of critical files, kstvtune.ax appeared in a number of places:

C:\WINDOWS\system32
C:\WINDOWS\Driver Cache\i386
C:\WINDOWS\LastGood\system32
C:\WINDOWS\RegisteredPackages\{Long CLSID}
C:\WINDOWS\System32\dllcache

I copied the older file into those locations, but Windows File Protection restored the newer file into C:\WINDOWS\system32 each time I fired up the TV tuner application. I tried copying the files over in Safe Mode (restart your computer and press to access it) and removed all instances of the newer kstvtune.ax file, but Windows File Protection still managed to restore the newer version. And, in Windows XP, disabling Windows File Protection requires you to hack a DLL.

It turned out that there was one copy left of kstvtune.ax that I had missed, inside the 70MB driver.cab archive in the C:\WINDOWS\Driver Cache\i386 directory. To fix that, I unpacked driver.cab with WinRAR in a directory of its own, after first having saved a copy in case anything went wrong. (Warning: this takes a long time, as there are over 4500 files in the archive, eating up some 322MB of disk space uncompressed.) Then I copied over the older version of kstvtune.ax, and used Cabpack 1.4 to rebuild the driver.cab file, and copied it over to the C:\WINDOWS\Driver Cache\i386 directory. This time, Windows File Protection didn’t mind the older version, and I had a working TV tuner card and Movie Maker was stable. Phew.

If you know what you’re doing, this process is one way to get around Windows File Protection to sort out small problems without reinstalling the operating system.

Warning

Please note: you need Administrator privileges for the below, and remember, tampering with operating system files and settings is inherently dangerous. Do not attempt it without backing up first.end box.

Join the newsletter!

Or

Sign up to gain exclusive access to email subscriptions, event invitations, competitions, giveaways, and much more.

Membership is free, and your security and privacy remain protected. View our privacy policy before signing up.

Error: Please check your email address.
Keep up with the latest tech news, reviews and previews by subscribing to the Good Gear Guide newsletter.

Juha Saarinen

PC World
Show Comments

Brand Post

Most Popular Reviews

Latest Articles

Resources

PCW Evaluation Team

Jack Jeffries

MSI GS75

As the Maserati or BMW of laptops, it would fit perfectly in the hands of a professional needing firepower under the hood, sophistication and class on the surface, and gaming prowess (sports mode if you will) in between.

Taylor Carr

MSI PS63

The MSI PS63 is an amazing laptop and I would definitely consider buying one in the future.

Christopher Low

Brother RJ-4230B

This small mobile printer is exactly what I need for invoicing and other jobs such as sending fellow tradesman details or step-by-step instructions that I can easily print off from my phone or the Web.

Aysha Strobbe

Microsoft Office 365/HP Spectre x360

Microsoft Office continues to make a student’s life that little bit easier by offering reliable, easy to use, time-saving functionality, while continuing to develop new features that further enhance what is already a formidable collection of applications

Michael Hargreaves

Microsoft Office 365/Dell XPS 15 2-in-1

I’d recommend a Dell XPS 15 2-in-1 and the new Windows 10 to anyone who needs to get serious work done (before you kick back on your couch with your favourite Netflix show.)

Maryellen Rose George

Brother PT-P750W

It’s useful for office tasks as well as pragmatic labelling of equipment and storage – just don’t get too excited and label everything in sight!

Featured Content

Product Launch Showcase

Don’t have an account? Sign up here

Don't have an account? Sign up now

Forgot password?