While they could argue it was derivative code, they would not own rights to the new code, only could argue that they wanted to stop its distribution without license.
And validity of any "we own everything about you" contracts gets kinda iffy if you're not paying the worker who went on "leave of absence"