Not only the individual strings are constant, but also the array itself.
return ret;
}
-static const char* aac_suffixes[] = {"m4a", "mp4", NULL};
+static const char * const aac_suffixes[] = {"m4a", "mp4", NULL};
/**
* the init function of the aac audio format handler
*
*/
void (*init)(struct audio_format_handler*);
/** Typical file endings for files that can be handled by this afh. */
- const char **suffixes;
+ const char * const *suffixes;
/**
* Check if this audio format handler can handle the file.
*
return ret;
}
-static const char* flac_suffixes[] = {"flac", NULL};
+static const char * const flac_suffixes[] = {"flac", NULL};
/**
* The init function of the flac audio format handler.
return 1;
}
-static const char* mp3_suffixes[] = {"mp3", NULL};
+static const char * const mp3_suffixes[] = {"mp3", NULL};
/**
* the init function of the mp3 audio format handler
PARA_ERROR_LOG("%s\n", para_strerror(-ret));
}
-static const char* ogg_suffixes[] = {"ogg", NULL};
-
static int vorbis_make_meta_packet(struct taginfo *tags, ogg_packet *result)
{
vorbis_comment vc;
free(packet.packet);
return ret;
}
+
+static const char * const ogg_suffixes[] = {"ogg", NULL};
+
/**
* The init function of the ogg vorbis audio format handler.
*
#include "opus_common.h"
#include "ogg_afh_common.h"
-static const char* opus_suffixes[] = {"opus", NULL};
+static const char * const opus_suffixes[] = {"opus", NULL};
#define OPUS_COMMENT_HEADER "OpusTags"
return 1;
}
-static const char* speex_suffixes[] = {"spx", "speex", NULL};
-
static int spx_packet_callback(ogg_packet *packet, int packet_num,
__a_unused int serial, struct afh_info *afhi,
void *private_data)
return ret;
}
+static const char * const speex_suffixes[] = {"spx", "speex", NULL};
+
/**
* The init function of the ogg/speex audio format handler.
*
return ret;
}
-static const char* wma_suffixes[] = {"wma", NULL};
+static const char * const wma_suffixes[] = {"wma", NULL};
/**
* The init function of the wma audio format handler.