forked from Lainports/freebsd-ports
flac.c:253:8: error: incompatible function pointer types passing 'FLAC__StreamDecoderReadStatus (const FLAC__StreamDecoder *, FLAC__byte *, unsigned int *, void *)' (aka 'FLAC__StreamDecoderReadStatus (const FLAC__StreamDecoder *, unsigned char *, unsigned int *, void *)') to parameter of type 'FLAC__StreamDecoderReadCallback' (aka 'FLAC__StreamDecoderReadStatus (*)(const FLAC__StreamDecoder *, unsigned char *, unsigned long *, void *)') [-Wincompatible-function-pointer-types]
fs_flac_read_callback,
^~~~~~~~~~~~~~~~~~~~~
/usr/local/include/FLAC/stream_decoder.h:1092:34: note: passing argument to parameter 'read_callback' here
FLAC__StreamDecoderReadCallback read_callback,
^
flac.c:597:8: error: incompatible function pointer types passing 'FLAC__StreamEncoderWriteStatus (const FLAC__StreamEncoder *, const FLAC__byte *, unsigned int, unsigned int, unsigned int, void *)' (aka 'FLAC__StreamEncoderWriteStatus (const FLAC__StreamEncoder *, const unsigned char *, unsigned int, unsigned int, unsigned int, void *)') to parameter of type 'FLAC__StreamEncoderWriteCallback' (aka 'FLAC__StreamEncoderWriteStatus (*)(const FLAC__StreamEncoder *, const unsigned char *, unsigned long, unsigned int, unsigned int, void *)') [-Wincompatible-function-pointer-types]
fs_flac_enc_write_callback,
^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/FLAC/stream_encoder.h:1532:136: note: passing argument to parameter 'write_callback' here
FLAC_API FLAC__StreamEncoderInitStatus FLAC__stream_encoder_init_stream(FLAC__StreamEncoder *encoder, FLAC__StreamEncoderWriteCallback write_callback, FLAC__StreamEncoderSeekCallback seek_callback, FLAC__StreamEncoderTellCallback tell_callback, FLAC__StreamEncoderMetadataCallback metadata_callback, void *client_data);
16 warnings and 2 errors generated.
Tested on: 14.0-CURRENT (1400093)
22 lines
1,014 B
C
22 lines
1,014 B
C
--- src/libfishsound/flac.c.orig 2010-02-03 13:34:02 UTC
|
|
+++ src/libfishsound/flac.c
|
|
@@ -106,7 +106,7 @@ fs_flac_command (FishSound * fsound, int command, void
|
|
#if FS_DECODE
|
|
static FLAC__StreamDecoderReadStatus
|
|
fs_flac_read_callback(const FLAC__StreamDecoder *decoder,
|
|
- FLAC__byte buffer[], unsigned int *bytes,
|
|
+ FLAC__byte buffer[], size_t *bytes,
|
|
void *client_data)
|
|
{
|
|
FishSound* fsound = (FishSound*)client_data;
|
|
@@ -346,8 +346,8 @@ dec_err:
|
|
#if FS_ENCODE
|
|
static FLAC__StreamEncoderWriteStatus
|
|
fs_flac_enc_write_callback(const FLAC__StreamEncoder *encoder,
|
|
- const FLAC__byte buffer[], unsigned bytes,
|
|
- unsigned samples, unsigned current_frame,
|
|
+ const FLAC__byte buffer[], size_t bytes,
|
|
+ uint32_t samples, uint32_t current_frame,
|
|
void *client_data)
|
|
{
|
|
FishSound* fsound = (FishSound*)client_data;
|