Copy array manually to work around vala bug

Closes: bgo #720703