X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvcl%2Fldp.c;h=34eba377451745f232104920f15f385ae69ad6b6;hb=9f3f18f99fd321cdcfc331e92b10b64f0ef590b3;hp=e53a61e8e8c0c9e8809eef12692d57de18119132;hpb=b7f035ff4c56cbfd8548c8f1a27fcffb79be6d1f;p=vpp.git diff --git a/src/vcl/ldp.c b/src/vcl/ldp.c index e53a61e8e8c..34eba377451 100644 --- a/src/vcl/ldp.c +++ b/src/vcl/ldp.c @@ -109,7 +109,11 @@ typedef struct #define LDBG(_lvl, _fmt, _args...) \ if (ldp->debug > _lvl) \ - clib_warning ("ldp<%d>: " _fmt, getpid(), ##_args) + { \ + int errno_saved = errno; \ + clib_warning ("ldp<%d>: " _fmt, getpid(), ##_args); \ + errno = errno_saved; \ + } static ldp_main_t ldp_main = { .vlsh_bit_val = (1 << LDP_SID_BIT_MIN),