Hi, I think this is a Ubuntu fault rather an avast problem.
From time to time, I have same error -I too run Hardy 8.04.1- with the muCommander (norton commander clone in Java) and gdmsetup -you know, opening the window to change login screen.
May be updating your distro to latest patchs can make it, I'm having not a single issue from a time now... (touch wood!)
BTW, avast's best AV out there =)
Best!