Fixed memory size caluclation problem.

See https://github.com/msgpack/msgpack-c/issues/149
Merge pull request #160 from redboltz/fix_memory_allocation

Fixed memory size caluclation problem.