New version with couple of fixes

I don't know all the fixes but I assume CS will overwrite this with
meaningful comments.