From f4158fd7685a465f2170b92401243dff0397fb01 Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Tue, 29 Jul 2014 18:21:44 +0200 Subject: [PATCH] Don't use errno as a local variable, because it's a macro. --- src/meshlink.c | 4 ++-- src/meshlink.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/meshlink.c b/src/meshlink.c index b27d97c6..80404370 100644 --- a/src/meshlink.c +++ b/src/meshlink.c @@ -629,8 +629,8 @@ static const char *errstr[] = { [MESHLINK_ENOENT] = "No such node", }; -const char *meshlink_strerror(meshlink_errno_t errno) { - return errstr[errno]; +const char *meshlink_strerror(meshlink_errno_t err) { + return errstr[err]; } static bool ecdsa_keygen(meshlink_handle_t *mesh) { diff --git a/src/meshlink.h b/src/meshlink.h index a21af570..85a0cb75 100644 --- a/src/meshlink.h +++ b/src/meshlink.h @@ -69,11 +69,11 @@ struct meshlink_channel { /// Get the text for the given MeshLink error code. /** This function returns a pointer to the string containing the description of the given error code. * - * @param errno An error code returned by MeshLink. + * @param err An error code returned by MeshLink. * * @return A pointer to a string containing the description of the error code. */ -extern const char *meshlink_strerror(meshlink_errno_t errno); +extern const char *meshlink_strerror(meshlink_errno_t err); /// Open or create a MeshLink instance. /** This function opens or creates a MeshLink instance. -- 2.39.2