Fix a bug reported by Vlad Hanciuta