MacOS: get instruction stream after closing buffer.

Otherwise the QByteArray's constData might have been relocated, and the
output might be anything but correct (e.g. empty).

Change-Id: I2eb1223d2e0577f41c8f9e6ce81cb65af05166da
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>