As NDAs and copyright violation usually do not go together, I'll provide some background:
Suppose that a company, we'll call them Olio, created a smartwatch that uses publicly available computer code from the Linux project. Under the terms of the GNU General Public License, Linux's copyright license, it is fine for Olio to use Linux in their smartwatch, under the condition that, if Olio makes any changes to Linux's code before putting it on their watch, they make their edited code publicly available. Well, Olio uses Linux, with changes to its code, in their watch, but they never released this edited code. A few years later, Olio goes bankrupt and is bought by another company, we'll call this company Flex. As part of the acquisition, Flex requires that all of Olio's employees sign NDAs barring them from disclosing just about any information about the Olio watch, including the edited Linux code, which, under Linux's copyright license, has to be publicly available until 2020 (three years after Olio's last official use of their modified Linux code).
If one of Olio's former employees with a copy of this edited Linux code were to release it, as required by Linux's copyright license, would they be punishable for violating the NDA?