misc: Add support for GError reporting.