Support for array serialisation. Tweaks to inputqueue