In ubuntu 12.04 VLC runs out of sync when pausing a video. First, when pausing the video, sound will continue playing for a couple of seconds. Then when resuming the video, it will lag behind but eventually resync after several seconds.
Somehow I lived with this bug for a while, unnecessarily as it seems as there is a workaround :
in /etc/pulse/daemon.conf edit/add the following entries:
default-sample-rate = 44100
alternate-sample-rate = 44100
The value 44100 is just indicative and was the default in my installation. The point of this exercise is that both values for default-sample-rate and alternate-sample-rate should be the same. Then restart pulseaudio like this:
service pulseaudio restart
Sound lags when opening video files 1