socket-properties: Implement MT-safe refcounting
Use atomic integer operation when dealing with refcounting, otherwise one could very easily end-up in leaked (bad) properties or double-freed (really bad) properties.
Should maybe also be backported to the previous stable branches