Skip to content

Commit df4ff09

Browse files
Merge pull request #23 from jean-edouard/n_pspecs
rpcgen: don't install an empty set of properties
2 parents d51a5fa + 9fcdda7 commit df4ff09

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

rpcgen/templates/template_obj_imp.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ static void @object@_object_class_init (@GLIB_CLASS@ *klass)
4848
@init_properties@
4949
gc->set_property = handle_set_property;
5050
gc->get_property = handle_get_property;
51-
g_object_class_install_properties(gc, N_PROPERTIES, obj_properties);
51+
if (N_PROPERTIES > 1)
52+
g_object_class_install_properties(gc, N_PROPERTIES, obj_properties);
5253
}
5354

5455
@GLIB_OBJ@ *@object@_create_glib_obj()

0 commit comments

Comments
 (0)