]> sigrok.org Git - libsigrok.git/commitdiff
error.c: Add missing SR_ERR_ARG and SR_ERR_NA.
authorUwe Hermann <redacted>
Tue, 16 Apr 2013 10:54:11 +0000 (12:54 +0200)
committerUwe Hermann <redacted>
Tue, 16 Apr 2013 10:54:11 +0000 (12:54 +0200)
error.c

diff --git a/error.c b/error.c
index 01fb791232efd1f17952d4b3f34412866b8eebdf..e3947a2f6409c0372521d7e024918361be4a1405 100644 (file)
--- a/error.c
+++ b/error.c
@@ -69,12 +69,18 @@ SR_API const char *sr_strerror(int error_code)
        case SR_ERR_MALLOC:
                str = "memory allocation error";
                break;
+       case SR_ERR_ARG:
+               str = "invalid argument";
+               break;
        case SR_ERR_BUG:
                str = "internal error";
                break;
        case SR_ERR_SAMPLERATE:
                str = "invalid samplerate";
                break;
+       case SR_ERR_NA:
+               str = "not applicable";
+               break;
        default:
                str = "unknown error";
                break;
@@ -120,12 +126,18 @@ SR_API const char *sr_strerror_name(int error_code)
        case SR_ERR_MALLOC:
                str = "SR_ERR_MALLOC";
                break;
+       case SR_ERR_ARG:
+               str = "SR_ERR_ARG";
+               break;
        case SR_ERR_BUG:
                str = "SR_ERR_BUG";
                break;
        case SR_ERR_SAMPLERATE:
                str = "SR_ERR_SAMPLERATE";
                break;
+       case SR_ERR_NA:
+               str = "SR_ERR_NA";
+               break;
        default:
                str = "unknown error code";
                break;