check for missing result of rate_ctr_group_alloc()

In case the counter group allocation fails, we must handle this
gracefully and fail the allocation of the parent object, too.

RelateD: OS#2361
Change-Id: I7dad4a4d52fe05f6b990359841b4408df5990e21
diff --git a/src/libbsc/net_init.c b/src/libbsc/net_init.c
index bc5ed35..4dfc258 100644
--- a/src/libbsc/net_init.c
+++ b/src/libbsc/net_init.c
@@ -61,6 +61,10 @@
 
 	/* init statistics */
 	net->bsc_ctrs = rate_ctr_group_alloc(net, &bsc_ctrg_desc, 0);
+	if (!net->bsc_ctrs) {
+		talloc_free(net);
+		return NULL;
+	}
 
 	gsm_net_update_ctype(net);