diff options
author | Jean-Marc Valin <jmvalin@jmvalin.ca> | 2011-09-01 21:46:18 +0400 |
---|---|---|
committer | Jean-Marc Valin <jmvalin@jmvalin.ca> | 2011-09-01 21:46:18 +0400 |
commit | f9265ddf25cc512788820a636df11dc002210639 (patch) | |
tree | 9ae2a5f097c97c2725a8746dd61fec60d051a92d | |
parent | 7fc2fbdb14af2ae7e9fb44cf56555f549ac65929 (diff) |
opus_strerror() and opus_get_version_string() moved to libcelt
-rw-r--r-- | libcelt/celt.c | 28 | ||||
-rw-r--r-- | src/opus.c | 26 |
2 files changed, 28 insertions, 26 deletions
diff --git a/libcelt/celt.c b/libcelt/celt.c index 03955680..6c0aafd7 100644 --- a/libcelt/celt.c +++ b/libcelt/celt.c @@ -2751,3 +2751,31 @@ bad_request: return OPUS_UNIMPLEMENTED; } + + +const char *opus_strerror(int error) +{ + static const char *error_strings[8] = { + "success", + "invalid argument", + "buffer too small", + "internal error", + "corrupted stream", + "request not implemented", + "invalid state", + "memory allocation failed" + }; + if (error > 0 || error < -7) + return "unknown error"; + else + return error_strings[-error]; +} + +const char *opus_get_version_string(void) +{ + return "libopus " OPUS_VERSION +#ifdef FUZZING + "-fuzzing" +#endif + ; +} @@ -49,29 +49,3 @@ int encode_size(int size, unsigned char *data) } } -const char *opus_strerror(int error) -{ - static const char *error_strings[8] = { - "success", - "invalid argument", - "buffer too small", - "internal error", - "corrupted stream", - "request not implemented", - "invalid state", - "memory allocation failed" - }; - if (error > 0 || error < -7) - return "unknown error"; - else - return error_strings[-error]; -} - -const char *opus_get_version_string(void) -{ - return "libopus " OPUS_VERSION -#ifdef FUZZING - "-fuzzing" -#endif - ; -} |