OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

46 lines
1.7 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../shadow/shadow-4.1.5-nscd-ignore-exit-1.patch
  5. # Copyright (C) 2012 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. From 357ff92218a68f2ea74b9d08867c662571012bbe Mon Sep 17 00:00:00 2001
  17. From: Mike Frysinger <vapier@gentoo.org>
  18. Date: Sun, 12 Feb 2012 23:37:04 -0500
  19. Subject: [PATCH 3/3] nscd: ignore exit 1 code
  20. If nscd is installed but not in use, then running `nscd -i` will exit(1).
  21. We shouldn't warn in this case since this is not abnormal behavior.
  22. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
  23. ---
  24. lib/nscd.c | 3 +++
  25. 1 files changed, 3 insertions(+), 0 deletions(-)
  26. diff --git a/lib/nscd.c b/lib/nscd.c
  27. index ea1dc55..7adb58f 100644
  28. --- a/lib/nscd.c
  29. +++ b/lib/nscd.c
  30. @@ -39,6 +39,9 @@ int nscd_flush_cache (const char *service)
  31. /* nscd is not installed, or it is installed but uses an
  32. interpreter that is missing. Probably the former. */
  33. return 0;
  34. + } else if (code == 1) {
  35. + /* nscd is installed, but it isn't active. */
  36. + return 0;
  37. } else if (code != 0) {
  38. (void) fprintf (stderr, _("%s: nscd exited with status %d\n"),
  39. Prog, code);
  40. --
  41. 1.7.8.4