diff options
author | Lennart Poettering <lennart@poettering.net> | 2008-08-19 22:39:54 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2008-08-19 22:39:54 +0200 |
commit | b7026bf248948a6a30386ddbcc137f48f369a51e (patch) | |
tree | 0941ba3f61298fd9b8cb5b34fc236248519b0c8f /src/pulse/scache.c | |
parent | 047eb52b521a61aef54bd1760b5470a963ea47b6 (diff) |
add a few more gcc warning flags and fix quite a few problems found by doing so
Diffstat (limited to 'src/pulse/scache.c')
-rw-r--r-- | src/pulse/scache.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/pulse/scache.c b/src/pulse/scache.c index 5e31e7af..fd3b9876 100644 --- a/src/pulse/scache.c +++ b/src/pulse/scache.c @@ -47,6 +47,7 @@ int pa_stream_connect_upload(pa_stream *s, size_t length) { PA_CHECK_VALIDITY(s->context, s->state == PA_STREAM_UNCONNECTED, PA_ERR_BADSTATE); PA_CHECK_VALIDITY(s->context, length > 0, PA_ERR_INVALID); + PA_CHECK_VALIDITY(s->context, length == (size_t) (uint32_t) length, PA_ERR_INVALID); if (!(name = pa_proplist_gets(s->proplist, PA_PROP_EVENT_ID))) name = pa_proplist_gets(s->proplist, PA_PROP_MEDIA_NAME); @@ -63,7 +64,7 @@ int pa_stream_connect_upload(pa_stream *s, size_t length) { pa_tagstruct_puts(t, name); pa_tagstruct_put_sample_spec(t, &s->sample_spec); pa_tagstruct_put_channel_map(t, &s->channel_map); - pa_tagstruct_putu32(t, length); + pa_tagstruct_putu32(t, (uint32_t) length); if (s->context->version >= 13) { pa_init_proplist(s->proplist); |