From bf7aacea49ee3f50542756cedba8095ca772b6ec Mon Sep 17 00:00:00 2001 From: grantseltzer Date: Mon, 3 Jan 2022 13:34:33 -0500 Subject: [PATCH] Fix comparison operator in API documentation --- docs/api.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/api.rst b/docs/api.rst index ea181af..7a8e709 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -43,7 +43,7 @@ For example: ptr = some_libbpf_api_returning_ptr(); if (!ptr) { /* note no minus sign for EINVAL and E2BIG below */ - if (errno = EINVAL) { + if (errno == EINVAL) { /* handle EINVAL error */ } else if (errno == E2BIG) { /* handle E2BIG error */