testsuite/refcounting/pad.c: fix test

Original commit message from CVS:
* testsuite/refcounting/pad.c: (main):
fix test
This commit is contained in:
Benjamin Otte 2004-04-22 05:08:19 +00:00
parent 0ebe57e7d5
commit a6c11fb9f8
3 changed files with 13 additions and 4 deletions

View file

@ -1,3 +1,8 @@
2004-04-22 Benjamin Otte <otte@gnome.org>
* testsuite/refcounting/pad.c: (main):
fix test
2004-04-22 Benjamin Otte <otte@gnome.org> 2004-04-22 Benjamin Otte <otte@gnome.org>
* gst/gstcaps.c: (gst_caps_subtract): * gst/gstcaps.c: (gst_caps_subtract):

View file

@ -132,14 +132,16 @@ main (int argc, gchar * argv[])
for (i = 0; i < iters; i++) { for (i = 0; i < iters; i++) {
padtempl = padtempl =
gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES, NULL); gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES,
gst_caps_new_any ());
gst_object_unref (GST_OBJECT (padtempl)); gst_object_unref (GST_OBJECT (padtempl));
} }
g_print ("%d padtemplates create/unref %ld\n", iters, vmsize () - usage1); g_print ("%d padtemplates create/unref %ld\n", iters, vmsize () - usage1);
for (i = 0; i < iters; i++) { for (i = 0; i < iters; i++) {
padtempl = padtempl =
gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES, NULL); gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES,
gst_caps_new_any ());
pad = gst_pad_new_from_template (padtempl, "sink1"); pad = gst_pad_new_from_template (padtempl, "sink1");
gst_object_unref (GST_OBJECT (pad)); gst_object_unref (GST_OBJECT (pad));
} }

View file

@ -132,14 +132,16 @@ main (int argc, gchar * argv[])
for (i = 0; i < iters; i++) { for (i = 0; i < iters; i++) {
padtempl = padtempl =
gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES, NULL); gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES,
gst_caps_new_any ());
gst_object_unref (GST_OBJECT (padtempl)); gst_object_unref (GST_OBJECT (padtempl));
} }
g_print ("%d padtemplates create/unref %ld\n", iters, vmsize () - usage1); g_print ("%d padtemplates create/unref %ld\n", iters, vmsize () - usage1);
for (i = 0; i < iters; i++) { for (i = 0; i < iters; i++) {
padtempl = padtempl =
gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES, NULL); gst_pad_template_new ("sink%d", GST_PAD_SINK, GST_PAD_SOMETIMES,
gst_caps_new_any ());
pad = gst_pad_new_from_template (padtempl, "sink1"); pad = gst_pad_new_from_template (padtempl, "sink1");
gst_object_unref (GST_OBJECT (pad)); gst_object_unref (GST_OBJECT (pad));
} }