fixing bug 1284

--HG--
extra : source : cb9a9ef17437c9b21dcf6d191dfad361a59a8bb7
Merge pull request #552 from einhverfr/master

fixing bug 1284