mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-28 08:26:14 +01:00
Merge branch 'fix_more_warnings' into 'master'
Fix more warnings See merge request GNOME/glib!2106
This commit is contained in:
commit
0c8740dc83
@ -49,7 +49,7 @@ static const TestData cases[] = {
|
|||||||
{ "true", NULL, EXPLICITLY_TRUE, REMOTE },
|
{ "true", NULL, EXPLICITLY_TRUE, REMOTE },
|
||||||
{ "false", NULL, EXPLICITLY_FALSE, REMOTE },
|
{ "false", NULL, EXPLICITLY_FALSE, REMOTE },
|
||||||
{ "we-close", "662100", EXPLICITLY_TRUE, LOCAL },
|
{ "we-close", "662100", EXPLICITLY_TRUE, LOCAL },
|
||||||
{ NULL }
|
{ NULL, NULL, 0, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
@ -502,7 +502,7 @@ test_ip_sync (GSocketFamily family)
|
|||||||
g_assert_cmpstr (testbuf, ==, buf);
|
g_assert_cmpstr (testbuf, ==, buf);
|
||||||
|
|
||||||
{
|
{
|
||||||
GOutputVector v[7] = { { NULL, }, };
|
GOutputVector v[7] = { { NULL, 0 }, };
|
||||||
|
|
||||||
v[0].buffer = testbuf2 + 0;
|
v[0].buffer = testbuf2 + 0;
|
||||||
v[0].size = 3;
|
v[0].size = 3;
|
||||||
@ -627,10 +627,10 @@ test_ip_sync_dgram (GSocketFamily family)
|
|||||||
g_assert_cmpstr (testbuf, ==, buf);
|
g_assert_cmpstr (testbuf, ==, buf);
|
||||||
|
|
||||||
{
|
{
|
||||||
GOutputMessage m[3] = { { NULL, }, };
|
GOutputMessage m[3] = { { NULL, NULL, 0, 0, NULL, 0 }, };
|
||||||
GInputMessage im[3] = { { NULL, }, };
|
GInputMessage im[3] = { { NULL, NULL, 0, 0, 0, NULL, 0 }, };
|
||||||
GOutputVector v[7] = { { NULL, }, };
|
GOutputVector v[7] = { { NULL, 0 }, };
|
||||||
GInputVector iv[7] = { { NULL, }, };
|
GInputVector iv[7] = { { NULL, 0 }, };
|
||||||
|
|
||||||
v[0].buffer = testbuf2 + 0;
|
v[0].buffer = testbuf2 + 0;
|
||||||
v[0].size = 3;
|
v[0].size = 3;
|
||||||
@ -868,8 +868,8 @@ test_ip_sync_dgram_timeouts (GSocketFamily family)
|
|||||||
/* Check for timeouts when no server is running. */
|
/* Check for timeouts when no server is running. */
|
||||||
{
|
{
|
||||||
gint64 start_time;
|
gint64 start_time;
|
||||||
GInputMessage im = { NULL, };
|
GInputMessage im = { NULL, NULL, 0, 0, 0, NULL, 0 };
|
||||||
GInputVector iv = { NULL, };
|
GInputVector iv = { NULL, 0 };
|
||||||
guint8 buf[128];
|
guint8 buf[128];
|
||||||
|
|
||||||
iv.buffer = buf;
|
iv.buffer = buf;
|
||||||
|
@ -112,7 +112,7 @@ test_types (void)
|
|||||||
vp2 = (gpointer) g_atomic_pointer_get (&gs);
|
vp2 = (gpointer) g_atomic_pointer_get (&gs);
|
||||||
gs2 = (gsize) vp2;
|
gs2 = (gsize) vp2;
|
||||||
g_assert_cmpuint (gs2, ==, 0);
|
g_assert_cmpuint (gs2, ==, 0);
|
||||||
res = g_atomic_pointer_compare_and_exchange (&gs, NULL, NULL);
|
res = g_atomic_pointer_compare_and_exchange (&gs, NULL, (gsize) NULL);
|
||||||
g_assert_true (res);
|
g_assert_true (res);
|
||||||
g_assert_cmpuint (gs, ==, 0);
|
g_assert_cmpuint (gs, ==, 0);
|
||||||
gs2 = (gsize) g_atomic_pointer_add (&gs, 5);
|
gs2 = (gsize) g_atomic_pointer_add (&gs, 5);
|
||||||
@ -129,7 +129,7 @@ test_types (void)
|
|||||||
g_assert_cmpuint (gs, ==, 8);
|
g_assert_cmpuint (gs, ==, 8);
|
||||||
|
|
||||||
g_assert_cmpint (g_atomic_int_get (csp), ==, s);
|
g_assert_cmpint (g_atomic_int_get (csp), ==, s);
|
||||||
g_assert_true (g_atomic_pointer_get (cspp) == csp);
|
g_assert_true (g_atomic_pointer_get ((const gint **) cspp) == csp);
|
||||||
|
|
||||||
/* repeat, without the macros */
|
/* repeat, without the macros */
|
||||||
#undef g_atomic_int_set
|
#undef g_atomic_int_set
|
||||||
|
@ -1100,7 +1100,8 @@ type_data_make_W (TypeNode *node,
|
|||||||
vtable = pnode->data->common.value_table;
|
vtable = pnode->data->common.value_table;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
static const GTypeValueTable zero_vtable = { NULL, };
|
static const GTypeValueTable zero_vtable =
|
||||||
|
{ NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL };
|
||||||
|
|
||||||
value_table = &zero_vtable;
|
value_table = &zero_vtable;
|
||||||
}
|
}
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
static struct {
|
static struct {
|
||||||
void *page;
|
void *page;
|
||||||
void *sample;
|
void *sample;
|
||||||
} pages[N_PAGES] = { { NULL, }, };
|
} pages[N_PAGES] = { { NULL, NULL }, };
|
||||||
|
|
||||||
static const guint magazine_probes[] = MAGAZINE_PROBES;
|
static const guint magazine_probes[] = MAGAZINE_PROBES;
|
||||||
#define N_MAGAZINE_PROBES G_N_ELEMENTS (magazine_probes)
|
#define N_MAGAZINE_PROBES G_N_ELEMENTS (magazine_probes)
|
||||||
|
Loading…
Reference in New Issue
Block a user