0036-patchlevel-36.patch 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. From http://ftp.gnu.org/pub/gnu/bash/bash-4.3-patches/bash43-036
  2. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
  3. BASH PATCH REPORT
  4. =================
  5. Bash-Release: 4.3
  6. Patch-ID: bash43-036
  7. Bug-Reported-by: emanuelczirai@cryptolab.net
  8. Bug-Reference-ID: <f962e4f556da5ebfadaf7afe9c78a8cb@cryptolab.net>
  9. Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2015-02/msg00071.html
  10. Bug-Description:
  11. When evaluating and setting integer variables, and the assignment fails to
  12. create a variable (for example, when performing an operation on an array
  13. variable with an invalid subscript), bash attempts to dereference a null
  14. pointer, causing a segmentation violation.
  15. Patch (apply with `patch -p0'):
  16. *** a/bash-20150206/variables.c 2015-01-23 20:39:27.000000000 -0500
  17. --- b/variables.c 2015-02-19 13:56:12.000000000 -0500
  18. ***************
  19. *** 2834,2841 ****
  20. v = bind_variable (lhs, rhs, 0);
  21. ! if (v && isint)
  22. ! VSETATTR (v, att_integer);
  23. !
  24. ! VUNSETATTR (v, att_invisible);
  25. return (v);
  26. --- 2834,2843 ----
  27. v = bind_variable (lhs, rhs, 0);
  28. ! if (v)
  29. ! {
  30. ! if (isint)
  31. ! VSETATTR (v, att_integer);
  32. ! VUNSETATTR (v, att_invisible);
  33. ! }
  34. return (v);
  35. *** a/bash-4.3/patchlevel.h 2012-12-29 10:47:57.000000000 -0500
  36. --- b/patchlevel.h 2014-03-20 20:01:28.000000000 -0400
  37. ***************
  38. *** 26,30 ****
  39. looks for to find the patch level (for the sccs version string). */
  40. ! #define PATCHLEVEL 35
  41. #endif /* _PATCHLEVEL_H_ */
  42. --- 26,30 ----
  43. looks for to find the patch level (for the sccs version string). */
  44. ! #define PATCHLEVEL 36
  45. #endif /* _PATCHLEVEL_H_ */