Increment the counter correctly.

Remember what I said about this library only being morally correct and
not reviewed or tested.  I ment it, if you don't accept that then go
away.