sound: some fixes from AndreiLux repo