aboutsummaryrefslogtreecommitdiffstats
path: root/libavutil/error.c
diff options
context:
space:
mode:
authorClément Bœsch <ubitux@gmail.com>2012-09-16 02:53:32 +0200
committerClément Bœsch <ubitux@gmail.com>2012-09-16 02:53:32 +0200
commit8b052207271cddc175e01c05af8c0b05e24d117c (patch)
tree2210305db05469b05d874d6765df0cbbdf88f628 /libavutil/error.c
parente3a1eb9edf65edda301f3a727f11e0224b9f5ae2 (diff)
downloadffmpeg-8b052207271cddc175e01c05af8c0b05e24d117c.tar.gz
lavu/error: make error_entries static const.
Diffstat (limited to 'libavutil/error.c')
-rw-r--r--libavutil/error.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavutil/error.c b/libavutil/error.c
index 7111644145..f49d214779 100644
--- a/libavutil/error.c
+++ b/libavutil/error.c
@@ -28,7 +28,7 @@ struct error_entry {
};
#define ERROR_TAG(tag) AVERROR_##tag, #tag
-struct error_entry error_entries[] = {
+static const struct error_entry error_entries[] = {
{ ERROR_TAG(BSF_NOT_FOUND), "Bitstream filter not found" },
{ ERROR_TAG(BUG), "Internal bug, should not have happened" },
{ ERROR_TAG(BUG2), "Internal bug, should not have happened" },
@@ -52,7 +52,7 @@ struct error_entry error_entries[] = {
int av_strerror(int errnum, char *errbuf, size_t errbuf_size)
{
int ret = 0, i;
- struct error_entry *entry = NULL;
+ const struct error_entry *entry = NULL;
for (i = 0; i < FF_ARRAY_ELEMS(error_entries); i++) {
if (errnum == error_entries[i].num) {
@@ -84,7 +84,7 @@ int main(void)
int i;
for (i = 0; i < FF_ARRAY_ELEMS(error_entries); i++) {
- struct error_entry *entry = &error_entries[i];
+ const struct error_entry *entry = &error_entries[i];
printf("%d: %s [%s]\n", entry->num, av_err2str(entry->num), entry->tag);
}