Code cleanup, adding license.