Probably fix #77, but difficult to test.