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.

60 lines
2.1 KiB

  1. From b53934eec71ab34eb3762a89cec326360a5b0bc5 Mon Sep 17 00:00:00 2001
  2. From: Willy Tarreau <w@1wt.eu>
  3. Date: Tue, 16 Sep 2014 11:31:31 +0200
  4. Subject: [PATCH 07/13] BUG/MEDIUM: config: propagate frontend to backend
  5. process binding again.
  6. This basically reverts 3507d5d ("MEDIUM: proxy: only adjust the backend's
  7. bind-process when already set"). It was needed during the transition to
  8. the new process binding method but is causing trouble now because frontend
  9. to backend binding is not properly propagated.
  10. This fix should be backported to 1.5.
  11. (cherry picked from commit 8a3478ed31a16904f45178c153f4649faf6de675)
  12. ---
  13. src/cfgparse.c | 15 ++++++---------
  14. 1 file changed, 6 insertions(+), 9 deletions(-)
  15. diff --git a/src/cfgparse.c b/src/cfgparse.c
  16. index 943eba0..5288600 100644
  17. --- a/src/cfgparse.c
  18. +++ b/src/cfgparse.c
  19. @@ -6165,9 +6165,8 @@ int check_config_validity()
  20. /* we force the backend to be present on at least all of
  21. * the frontend's processes.
  22. */
  23. - if (target->bind_proc)
  24. - target->bind_proc = curproxy->bind_proc ?
  25. - (target->bind_proc | curproxy->bind_proc) : 0;
  26. + target->bind_proc = curproxy->bind_proc ?
  27. + (target->bind_proc | curproxy->bind_proc) : 0;
  28. /* Emit a warning if this proxy also has some servers */
  29. if (curproxy->srv) {
  30. @@ -6203,9 +6202,8 @@ int check_config_validity()
  31. /* we force the backend to be present on at least all of
  32. * the frontend's processes.
  33. */
  34. - if (target->bind_proc)
  35. - target->bind_proc = curproxy->bind_proc ?
  36. - (target->bind_proc | curproxy->bind_proc) : 0;
  37. + target->bind_proc = curproxy->bind_proc ?
  38. + (target->bind_proc | curproxy->bind_proc) : 0;
  39. }
  40. }
  41. }
  42. @@ -6257,9 +6255,8 @@ int check_config_validity()
  43. /* we force the backend to be present on at least all of
  44. * the frontend's processes.
  45. */
  46. - if (target->bind_proc)
  47. - target->bind_proc = curproxy->bind_proc ?
  48. - (target->bind_proc | curproxy->bind_proc) : 0;
  49. + target->bind_proc = curproxy->bind_proc ?
  50. + (target->bind_proc | curproxy->bind_proc) : 0;
  51. }
  52. }
  53. --
  54. 1.8.5.5