diff --git a/GI/Atk.hs b/GI/Atk.hs
--- a/GI/Atk.hs
+++ b/GI/Atk.hs
@@ -107,6 +107,7 @@
 actionGetDescription _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_action_get_description _obj' i
+    checkUnexpectedReturnNULL "atk_action_get_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -134,6 +135,7 @@
 actionGetKeybinding _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_action_get_keybinding _obj' i
+    checkUnexpectedReturnNULL "atk_action_get_keybinding" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -161,6 +163,7 @@
 actionGetLocalizedName _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_action_get_localized_name _obj' i
+    checkUnexpectedReturnNULL "atk_action_get_localized_name" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -212,6 +215,7 @@
 actionGetName _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_action_get_name _obj' i
+    checkUnexpectedReturnNULL "atk_action_get_name" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -527,6 +531,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let coord_type' = (fromIntegral . fromEnum) coord_type
     result <- atk_component_ref_accessible_at_point _obj' x y coord_type'
+    checkUnexpectedReturnNULL "atk_component_ref_accessible_at_point" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -753,6 +758,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     attribute_name' <- textToCString attribute_name
     result <- atk_document_get_attribute_value _obj' attribute_name'
+    checkUnexpectedReturnNULL "atk_document_get_attribute_value" result
     result' <- cstringToText result
     touchManagedPtr _obj
     freeMem attribute_name'
@@ -779,6 +785,7 @@
 documentGetAttributes _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_document_get_attributes _obj'
+    checkUnexpectedReturnNULL "atk_document_get_attributes" result
     result' <- unpackGSList result
     touchManagedPtr _obj
     return result'
@@ -852,6 +859,7 @@
 documentGetDocumentType _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_document_get_document_type _obj'
+    checkUnexpectedReturnNULL "atk_document_get_document_type" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -877,6 +885,7 @@
 documentGetLocale _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_document_get_locale _obj'
+    checkUnexpectedReturnNULL "atk_document_get_locale" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -1464,6 +1473,7 @@
 gObjectAccessibleGetObject _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_gobject_accessible_get_object _obj'
+    checkUnexpectedReturnNULL "atk_gobject_accessible_get_object" result
     result' <- (newObject GObject.Object) result
     touchManagedPtr _obj
     return result'
@@ -1489,6 +1499,7 @@
 gObjectAccessibleForObject obj = liftIO $ do
     let obj' = unsafeManagedPtrCastPtr obj
     result <- atk_gobject_accessible_for_object obj'
+    checkUnexpectedReturnNULL "atk_gobject_accessible_for_object" result
     result' <- (newObject Object) result
     touchManagedPtr obj
     return result'
@@ -1585,6 +1596,7 @@
 hyperlinkGetObject _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_hyperlink_get_object _obj' i
+    checkUnexpectedReturnNULL "atk_hyperlink_get_object" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -1636,6 +1648,7 @@
 hyperlinkGetUri _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_hyperlink_get_uri _obj' i
+    checkUnexpectedReturnNULL "atk_hyperlink_get_uri" result
     result' <- cstringToText result
     freeMem result
     touchManagedPtr _obj
@@ -1785,6 +1798,7 @@
 hyperlinkImplGetHyperlink _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_hyperlink_impl_get_hyperlink _obj'
+    checkUnexpectedReturnNULL "atk_hyperlink_impl_get_hyperlink" result
     result' <- (wrapObject Hyperlink) result
     touchManagedPtr _obj
     return result'
@@ -1844,6 +1858,7 @@
 hypertextGetLink _obj link_index = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_hypertext_get_link _obj' link_index
+    checkUnexpectedReturnNULL "atk_hypertext_get_link" result
     result' <- (newObject Hyperlink) result
     touchManagedPtr _obj
     return result'
@@ -1970,6 +1985,7 @@
 imageGetImageDescription _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_image_get_image_description _obj'
+    checkUnexpectedReturnNULL "atk_image_get_image_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -1995,6 +2011,7 @@
 imageGetImageLocale _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_image_get_image_locale _obj'
+    checkUnexpectedReturnNULL "atk_image_get_image_locale" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -2113,6 +2130,7 @@
 implementorRefAccessible _obj = liftIO $ do
     let _obj' = unsafeManagedPtrGetPtr _obj
     result <- atk_implementor_ref_accessible _obj'
+    checkUnexpectedReturnNULL "atk_implementor_ref_accessible" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -2354,6 +2372,7 @@
     m Misc
 miscGetInstance  = liftIO $ do
     result <- atk_misc_get_instance
+    checkUnexpectedReturnNULL "atk_misc_get_instance" result
     result' <- (newObject Misc) result
     return result'
 
@@ -2399,6 +2418,7 @@
 noOpObjectNew obj = liftIO $ do
     let obj' = unsafeManagedPtrCastPtr obj
     result <- atk_no_op_object_new obj'
+    checkUnexpectedReturnNULL "atk_no_op_object_new" result
     result' <- (wrapObject NoOpObject) result
     touchManagedPtr obj
     return result'
@@ -2442,6 +2462,7 @@
     m NoOpObjectFactory
 noOpObjectFactoryNew  = liftIO $ do
     result <- atk_no_op_object_factory_new
+    checkUnexpectedReturnNULL "atk_no_op_object_factory_new" result
     result' <- (wrapObject NoOpObjectFactory) result
     return result'
 
@@ -2519,6 +2540,7 @@
 objectGetAttributes _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_get_attributes _obj'
+    checkUnexpectedReturnNULL "atk_object_get_attributes" result
     result' <- unpackGSList result
     g_slist_free result
     touchManagedPtr _obj
@@ -2545,6 +2567,7 @@
 objectGetDescription _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_get_description _obj'
+    checkUnexpectedReturnNULL "atk_object_get_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -2667,6 +2690,7 @@
 objectGetName _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_get_name _obj'
+    checkUnexpectedReturnNULL "atk_object_get_name" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -2692,6 +2716,7 @@
 objectGetObjectLocale _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_get_object_locale _obj'
+    checkUnexpectedReturnNULL "atk_object_get_object_locale" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -2717,6 +2742,7 @@
 objectGetParent _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_get_parent _obj'
+    checkUnexpectedReturnNULL "atk_object_get_parent" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -2822,6 +2848,7 @@
 objectPeekParent _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_peek_parent _obj'
+    checkUnexpectedReturnNULL "atk_object_peek_parent" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -2849,6 +2876,7 @@
 objectRefAccessibleChild _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_ref_accessible_child _obj' i
+    checkUnexpectedReturnNULL "atk_object_ref_accessible_child" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -2874,6 +2902,7 @@
 objectRefRelationSet _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_ref_relation_set _obj'
+    checkUnexpectedReturnNULL "atk_object_ref_relation_set" result
     result' <- (wrapObject RelationSet) result
     touchManagedPtr _obj
     return result'
@@ -2899,6 +2928,7 @@
 objectRefStateSet _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_object_ref_state_set _obj'
+    checkUnexpectedReturnNULL "atk_object_ref_state_set" result
     result' <- (wrapObject StateSet) result
     touchManagedPtr _obj
     return result'
@@ -3369,6 +3399,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let obj' = unsafeManagedPtrCastPtr obj
     result <- atk_object_factory_create_accessible _obj' obj'
+    checkUnexpectedReturnNULL "atk_object_factory_create_accessible" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     touchManagedPtr obj
@@ -3462,6 +3493,7 @@
     m Plug
 plugNew  = liftIO $ do
     result <- atk_plug_new
+    checkUnexpectedReturnNULL "atk_plug_new" result
     result' <- (wrapObject Plug) result
     return result'
 
@@ -3486,6 +3518,7 @@
 plugGetId _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_plug_get_id _obj'
+    checkUnexpectedReturnNULL "atk_plug_get_id" result
     result' <- cstringToText result
     freeMem result
     touchManagedPtr _obj
@@ -3585,6 +3618,7 @@
     let upper_limit' = realToFrac upper_limit
     description' <- textToCString description
     result <- atk_range_new lower_limit' upper_limit' description'
+    checkUnexpectedReturnNULL "atk_range_new" result
     result' <- (wrapBoxed Range) result
     freeMem description'
     return result'
@@ -3610,6 +3644,7 @@
 rangeCopy _obj = liftIO $ do
     let _obj' = unsafeManagedPtrGetPtr _obj
     result <- atk_range_copy _obj'
+    checkUnexpectedReturnNULL "atk_range_copy" result
     result' <- (wrapBoxed Range) result
     touchManagedPtr _obj
     return result'
@@ -3659,6 +3694,7 @@
 rangeGetDescription _obj = liftIO $ do
     let _obj' = unsafeManagedPtrGetPtr _obj
     result <- atk_range_get_description _obj'
+    checkUnexpectedReturnNULL "atk_range_get_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -3789,6 +3825,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let type_' = gtypeToCGType type_
     result <- atk_registry_get_factory _obj' type_'
+    checkUnexpectedReturnNULL "atk_registry_get_factory" result
     result' <- (newObject ObjectFactory) result
     touchManagedPtr _obj
     return result'
@@ -3899,6 +3936,7 @@
     targets'' <- packPtrArray targets'
     let relationship' = (fromIntegral . fromEnum) relationship
     result <- atk_relation_new targets'' n_targets relationship'
+    checkUnexpectedReturnNULL "atk_relation_new" result
     result' <- (wrapObject Relation) result
     mapM_ touchManagedPtr targets
     freeMem targets''
@@ -3978,6 +4016,7 @@
 relationGetTarget _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_relation_get_target _obj'
+    checkUnexpectedReturnNULL "atk_relation_get_target" result
     result' <- unpackGPtrArray result
     result'' <- mapM (newObject Object) result'
     touchManagedPtr _obj
@@ -4051,6 +4090,7 @@
     m RelationSet
 relationSetNew  = liftIO $ do
     result <- atk_relation_set_new
+    checkUnexpectedReturnNULL "atk_relation_set_new" result
     result' <- (wrapObject RelationSet) result
     return result'
 
@@ -4220,6 +4260,7 @@
 relationSetGetRelation _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_relation_set_get_relation _obj' i
+    checkUnexpectedReturnNULL "atk_relation_set_get_relation" result
     result' <- (newObject Relation) result
     touchManagedPtr _obj
     return result'
@@ -4248,6 +4289,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let relationship' = (fromIntegral . fromEnum) relationship
     result <- atk_relation_set_get_relation_by_type _obj' relationship'
+    checkUnexpectedReturnNULL "atk_relation_set_get_relation_by_type" result
     result' <- (newObject Relation) result
     touchManagedPtr _obj
     return result'
@@ -4873,6 +4915,7 @@
 selectionRefSelection _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_selection_ref_selection _obj' i
+    checkUnexpectedReturnNULL "atk_selection_ref_selection" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -5006,6 +5049,7 @@
     m Socket
 socketNew  = liftIO $ do
     result <- atk_socket_new
+    checkUnexpectedReturnNULL "atk_socket_new" result
     result' <- (wrapObject Socket) result
     return result'
 
@@ -5101,6 +5145,7 @@
     m StateSet
 stateSetNew  = liftIO $ do
     result <- atk_state_set_new
+    checkUnexpectedReturnNULL "atk_state_set_new" result
     result' <- (wrapObject StateSet) result
     return result'
 
@@ -5187,6 +5232,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let compare_set' = unsafeManagedPtrCastPtr compare_set
     result <- atk_state_set_and_sets _obj' compare_set'
+    checkUnexpectedReturnNULL "atk_state_set_and_sets" result
     result' <- (wrapObject StateSet) result
     touchManagedPtr _obj
     touchManagedPtr compare_set
@@ -5325,6 +5371,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let compare_set' = unsafeManagedPtrCastPtr compare_set
     result <- atk_state_set_or_sets _obj' compare_set'
+    checkUnexpectedReturnNULL "atk_state_set_or_sets" result
     result' <- (wrapObject StateSet) result
     touchManagedPtr _obj
     touchManagedPtr compare_set
@@ -5382,6 +5429,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     let compare_set' = unsafeManagedPtrCastPtr compare_set
     result <- atk_state_set_xor_sets _obj' compare_set'
+    checkUnexpectedReturnNULL "atk_state_set_xor_sets" result
     result' <- (wrapObject StateSet) result
     touchManagedPtr _obj
     touchManagedPtr compare_set
@@ -5569,6 +5617,7 @@
 streamableContentGetMimeType _obj i = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_streamable_content_get_mime_type _obj' i
+    checkUnexpectedReturnNULL "atk_streamable_content_get_mime_type" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -5621,6 +5670,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     mime_type' <- textToCString mime_type
     result <- atk_streamable_content_get_stream _obj' mime_type'
+    checkUnexpectedReturnNULL "atk_streamable_content_get_stream" result
     result' <- (wrapBoxed GLib.IOChannel) result
     touchManagedPtr _obj
     freeMem mime_type'
@@ -5650,6 +5700,7 @@
     let _obj' = unsafeManagedPtrCastPtr _obj
     mime_type' <- textToCString mime_type
     result <- atk_streamable_content_get_uri _obj' mime_type'
+    checkUnexpectedReturnNULL "atk_streamable_content_get_uri" result
     result' <- cstringToText result
     touchManagedPtr _obj
     freeMem mime_type'
@@ -5740,6 +5791,7 @@
 tableGetCaption _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_caption _obj'
+    checkUnexpectedReturnNULL "atk_table_get_caption" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -5793,6 +5845,7 @@
 tableGetColumnDescription _obj column = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_column_description _obj' column
+    checkUnexpectedReturnNULL "atk_table_get_column_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -5848,6 +5901,7 @@
 tableGetColumnHeader _obj column = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_column_header _obj' column
+    checkUnexpectedReturnNULL "atk_table_get_column_header" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -5977,6 +6031,7 @@
 tableGetRowDescription _obj row = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_row_description _obj' row
+    checkUnexpectedReturnNULL "atk_table_get_row_description" result
     result' <- cstringToText result
     touchManagedPtr _obj
     return result'
@@ -6032,6 +6087,7 @@
 tableGetRowHeader _obj row = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_row_header _obj' row
+    checkUnexpectedReturnNULL "atk_table_get_row_header" result
     result' <- (newObject Object) result
     touchManagedPtr _obj
     return result'
@@ -6109,6 +6165,7 @@
 tableGetSummary _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_get_summary _obj'
+    checkUnexpectedReturnNULL "atk_table_get_summary" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -6221,6 +6278,7 @@
 tableRefAt _obj row column = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_ref_at _obj' row column
+    checkUnexpectedReturnNULL "atk_table_ref_at" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -6788,6 +6846,7 @@
 tableCellGetColumnHeaderCells _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_cell_get_column_header_cells _obj'
+    checkUnexpectedReturnNULL "atk_table_cell_get_column_header_cells" result
     result' <- unpackGPtrArray result
     result'' <- mapM (wrapObject Object) result'
     unrefPtrArray result
@@ -6913,6 +6972,7 @@
 tableCellGetRowHeaderCells _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_cell_get_row_header_cells _obj'
+    checkUnexpectedReturnNULL "atk_table_cell_get_row_header_cells" result
     result' <- unpackGPtrArray result
     result'' <- mapM (wrapObject Object) result'
     unrefPtrArray result
@@ -6964,6 +7024,7 @@
 tableCellGetTable _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_table_cell_get_table _obj'
+    checkUnexpectedReturnNULL "atk_table_cell_get_table" result
     result' <- (wrapObject Object) result
     touchManagedPtr _obj
     return result'
@@ -7040,6 +7101,7 @@
     let x_clip_type' = (fromIntegral . fromEnum) x_clip_type
     let y_clip_type' = (fromIntegral . fromEnum) y_clip_type
     result <- atk_text_get_bounded_ranges _obj' rect' coord_type' x_clip_type' y_clip_type'
+    checkUnexpectedReturnNULL "atk_text_get_bounded_ranges" result
     result' <- unpackZeroTerminatedPtrArray result
     result'' <- mapM (wrapBoxed TextRange) result'
     freeMem result
@@ -7180,6 +7242,7 @@
 textGetDefaultAttributes _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_text_get_default_attributes _obj'
+    checkUnexpectedReturnNULL "atk_text_get_default_attributes" result
     result' <- unpackGSList result
     g_slist_free result
     touchManagedPtr _obj
@@ -7302,6 +7365,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_run_attributes _obj' offset start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_run_attributes" result
     result' <- unpackGSList result
     g_slist_free result
     start_offset' <- peek start_offset
@@ -7338,6 +7402,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_selection _obj' selection_num start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_selection" result
     result' <- cstringToText result
     freeMem result
     start_offset' <- peek start_offset
@@ -7377,6 +7442,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_string_at_offset _obj' offset granularity' start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_string_at_offset" result
     result' <- cstringToText result
     freeMem result
     start_offset' <- peek start_offset
@@ -7411,6 +7477,7 @@
 textGetText _obj start_offset end_offset = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_text_get_text _obj' start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_text" result
     result' <- cstringToText result
     freeMem result
     touchManagedPtr _obj
@@ -7446,6 +7513,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_text_after_offset _obj' offset boundary_type' start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_text_after_offset" result
     result' <- cstringToText result
     freeMem result
     start_offset' <- peek start_offset
@@ -7485,6 +7553,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_text_at_offset _obj' offset boundary_type' start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_text_at_offset" result
     result' <- cstringToText result
     freeMem result
     start_offset' <- peek start_offset
@@ -7524,6 +7593,7 @@
     start_offset <- allocMem :: IO (Ptr Int32)
     end_offset <- allocMem :: IO (Ptr Int32)
     result <- atk_text_get_text_before_offset _obj' offset boundary_type' start_offset end_offset
+    checkUnexpectedReturnNULL "atk_text_get_text_before_offset" result
     result' <- cstringToText result
     freeMem result
     start_offset' <- peek start_offset
@@ -8325,6 +8395,7 @@
 valueGetRange _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_value_get_range _obj'
+    checkUnexpectedReturnNULL "atk_value_get_range" result
     result' <- (wrapBoxed Range) result
     touchManagedPtr _obj
     return result'
@@ -8350,6 +8421,7 @@
 valueGetSubRanges _obj = liftIO $ do
     let _obj' = unsafeManagedPtrCastPtr _obj
     result <- atk_value_get_sub_ranges _obj'
+    checkUnexpectedReturnNULL "atk_value_get_sub_ranges" result
     result' <- unpackGSList result
     result'' <- mapM (wrapBoxed Range) result'
     g_slist_free result
@@ -9028,6 +9100,7 @@
     m Registry
 getDefaultRegistry  = liftIO $ do
     result <- atk_get_default_registry
+    checkUnexpectedReturnNULL "atk_get_default_registry" result
     result' <- (wrapObject Registry) result
     return result'
 
@@ -9048,6 +9121,7 @@
     m Object
 getFocusObject  = liftIO $ do
     result <- atk_get_focus_object
+    checkUnexpectedReturnNULL "atk_get_focus_object" result
     result' <- (newObject Object) result
     return result'
 
@@ -9144,6 +9218,7 @@
     m Object
 getRoot  = liftIO $ do
     result <- atk_get_root
+    checkUnexpectedReturnNULL "atk_get_root" result
     result' <- (newObject Object) result
     return result'
 
@@ -9164,6 +9239,7 @@
     m T.Text
 getToolkitName  = liftIO $ do
     result <- atk_get_toolkit_name
+    checkUnexpectedReturnNULL "atk_get_toolkit_name" result
     result' <- cstringToText result
     return result'
 
@@ -9184,6 +9260,7 @@
     m T.Text
 getToolkitVersion  = liftIO $ do
     result <- atk_get_toolkit_version
+    checkUnexpectedReturnNULL "atk_get_toolkit_version" result
     result' <- cstringToText result
     return result'
 
@@ -9204,6 +9281,7 @@
     m T.Text
 getVersion  = liftIO $ do
     result <- atk_get_version
+    checkUnexpectedReturnNULL "atk_get_version" result
     result' <- cstringToText result
     return result'
 
@@ -9251,6 +9329,7 @@
 relationTypeGetName type_ = liftIO $ do
     let type_' = (fromIntegral . fromEnum) type_
     result <- atk_relation_type_get_name type_'
+    checkUnexpectedReturnNULL "atk_relation_type_get_name" result
     result' <- cstringToText result
     return result'
 
@@ -9385,6 +9464,7 @@
 roleGetLocalizedName role = liftIO $ do
     let role' = (fromIntegral . fromEnum) role
     result <- atk_role_get_localized_name role'
+    checkUnexpectedReturnNULL "atk_role_get_localized_name" result
     result' <- cstringToText result
     return result'
 
@@ -9408,6 +9488,7 @@
 roleGetName role = liftIO $ do
     let role' = (fromIntegral . fromEnum) role
     result <- atk_role_get_name role'
+    checkUnexpectedReturnNULL "atk_role_get_name" result
     result' <- cstringToText result
     return result'
 
@@ -9479,6 +9560,7 @@
 stateTypeGetName type_ = liftIO $ do
     let type_' = (fromIntegral . fromEnum) type_
     result <- atk_state_type_get_name type_'
+    checkUnexpectedReturnNULL "atk_state_type_get_name" result
     result' <- cstringToText result
     return result'
 
@@ -9550,6 +9632,7 @@
 textAttributeGetName attr = liftIO $ do
     let attr' = (fromIntegral . fromEnum) attr
     result <- atk_text_attribute_get_name attr'
+    checkUnexpectedReturnNULL "atk_text_attribute_get_name" result
     result' <- cstringToText result
     return result'
 
@@ -9575,6 +9658,7 @@
 textAttributeGetValue attr index_ = liftIO $ do
     let attr' = (fromIntegral . fromEnum) attr
     result <- atk_text_attribute_get_value attr' index_
+    checkUnexpectedReturnNULL "atk_text_attribute_get_value" result
     result' <- cstringToText result
     return result'
 
@@ -9643,6 +9727,7 @@
 valueTypeGetLocalizedName value_type = liftIO $ do
     let value_type' = (fromIntegral . fromEnum) value_type
     result <- atk_value_type_get_localized_name value_type'
+    checkUnexpectedReturnNULL "atk_value_type_get_localized_name" result
     result' <- cstringToText result
     return result'
 
@@ -9666,6 +9751,7 @@
 valueTypeGetName value_type = liftIO $ do
     let value_type' = (fromIntegral . fromEnum) value_type
     result <- atk_value_type_get_name value_type'
+    checkUnexpectedReturnNULL "atk_value_type_get_name" result
     result' <- cstringToText result
     return result'
 
diff --git a/LICENSE b/LICENSE
--- a/LICENSE
+++ b/LICENSE
@@ -454,49 +454,3 @@
 FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
 SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
 DAMAGES.
-
-                     END OF TERMS AND CONDITIONS
-
-           How to Apply These Terms to Your New Libraries
-
-  If you develop a new library, and you want it to be of the greatest
-possible use to the public, we recommend making it free software that
-everyone can redistribute and change.  You can do so by permitting
-redistribution under these terms (or, alternatively, under the terms of the
-ordinary General Public License).
-
-  To apply these terms, attach the following notices to the library.  It is
-safest to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least the
-"copyright" line and a pointer to where the full notice is found.
-
-    <one line to give the library's name and a brief idea of what it does.>
-    Copyright (C) <year>  <name of author>
-
-    This library is free software; you can redistribute it and/or
-    modify it under the terms of the GNU Lesser General Public
-    License as published by the Free Software Foundation; either
-    version 2.1 of the License, or (at your option) any later version.
-
-    This library is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-    Lesser General Public License for more details.
-
-    You should have received a copy of the GNU Lesser General Public
-    License along with this library; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
-
-Also add information on how to contact you by electronic and paper mail.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the library, if
-necessary.  Here is a sample; alter the names:
-
-  Yoyodyne, Inc., hereby disclaims all copyright interest in the
-  library `Frob' (a library for tweaking knobs) written by James Random Hacker.
-
-  <signature of Ty Coon>, 1 April 1990
-  Ty Coon, President of Vice
-
-That's all there is to it!
diff --git a/gi-atk.cabal b/gi-atk.cabal
--- a/gi-atk.cabal
+++ b/gi-atk.cabal
@@ -1,6 +1,6 @@
 -- Autogenerated, do not edit.
 name:               gi-atk
-version:            0.2.16.9
+version:            0.2.16.10
 synopsis:           Atk bindings
 description:        Bindings for Atk, autogenerated by haskell-gi.
 homepage:           https://github.com/haskell-gi/haskell-gi
@@ -16,10 +16,10 @@
     default-language:   Haskell2010
     exposed-modules:    GI.Atk, GI.AtkAttributes, GI.AtkSignals
     pkgconfig-depends:  atk >= 2.16
-    build-depends: base >= 4.6 && <4.9,
-        haskell-gi-base >= 0.9 && < 1,
-        gi-glib >= 0.2.44.9 && < 0.3,
-        gi-gobject >= 0.2.44.9 && < 0.3,
+    build-depends: base >= 4.7 && <5,
+        haskell-gi-base >= 0.10 && < 1,
+        gi-glib >= 0.2.44.10 && < 0.3,
+        gi-gobject >= 0.2.44.10 && < 0.3,
         bytestring >= 0.10,
         containers >= 0.5,
         text >= 1.0,
