Files
asterisk/main
Terry Wilson d12db0c76b Don't read past end of input when calling write()
int blah = 1;
...
write(chan->alertpipe[1], &blah, new_frames * sizeof(blah)) !=
(new_frames * sizeof(blah)))

is only valid when new_frames == 1. Otherwise we start reading into adjacent
variables declared on the stack. The read end discards what is read, so the
values don't matter but it's not a good idea to read past where we want even
though new_frames is almost always 1 and should never be large. This patch is
basically taken out of kpfleming's eventfd branch, as he mentioned that he
remembered fixing it there when I talked to him about this issue.

Review: https://reviewboard.asterisk.org/r/1583/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@345163 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-11-14 19:05:09 +00:00
..
2010-12-20 09:14:29 +00:00
2011-06-01 23:11:55 +00:00
2011-09-26 19:30:39 +00:00
2007-12-11 22:20:22 +00:00
2011-06-10 15:29:00 +00:00
2011-09-13 07:11:36 +00:00
2010-06-17 17:23:43 +00:00
2008-07-21 21:00:47 +00:00
2009-03-18 02:28:55 +00:00
2011-04-20 05:25:15 +00:00
2011-10-11 00:43:14 +00:00
2010-05-18 22:48:51 +00:00
2010-04-22 18:07:02 +00:00