Fixes and additions to the Common and Tasync modules needed for C++ bridge

These commits are included in the C++ bridge branch but I wanted to extract them so that they can be merged sooner. While the changes in the Tasync module are only needed in the C++ bridge, the changes in the Common module might also be useful for other parts webgme.