Building libacanberra-0.9 on OS X 10.4, I get a compiler warning:

read-wav.c: In function 'skip_to_chunk':
read-wav.c:63: warning: passing argument 2 of 'fseek' as signed due to prototype

Looking there, I see (extracting the relevant lines from that function):

        uint32_t s;
[...] 
       s = PA_UINT32_FROM_LE(chunk[1]);
[...]
            *size = s;
[size is a uint32_t parameter to this function)]
[...]
       if (fseek(w->file, s, SEEK_CUR) < 0)
            return CA_ERROR_SYSTEM;
[fseek() second parameter is prototyped as "long")]

I assume the goal is to move ahead chunk[1] in the file, so it seems
like "unsigned" it the right idea. Any chance that the unsigned
chunk[1] would be a larger (obviously positive) number than a signed
int can hold, or can we just cast it to a signed and silence the
warning?

dan

-- 
Daniel Macks
[EMAIL PROTECTED]
http://www.netspace.org/~dmacks

_______________________________________________
libcanberra-discuss mailing list
[email protected]
https://tango.0pointer.de/mailman/listinfo/libcanberra-discuss

Reply via email to