This patch fixes two problems pointed out by a static analysis tool.
* In chan_dahdi, when an event is handled the index of the sub channel is first
obtained. In very off nominal cases, the method that determines the index
can return a negative value. In the event handling code, whether or not
the index returned is valid was being checked after that value was used to
index into an array. This patch makes it so the value is checked before
any indexing is done.
* In res_calendar_ews, sizeof was being passed a pointer instead of the struct to
determine the amount of memory to allocate.
(issue ASTERISK-19651)
Reported by: Matt Jordan
(closes issue ASTERISK-19671)
Reported by: Matt Jordan
........
Merged revisions 366740 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 366741 from http://svn.asterisk.org/svn/asterisk/branches/10
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@366746 65c4cc65-6c06-0410-ace0-fbb531ad65f3
If the XML calendar data returned by a Microsoft Exchange Web Service
specifies an XML Event E-Mail Address ("EmailAddress"), and no e-mail address
is provided, a condition existed where an ast_calendar_attendee struct would
be allocated but not appended to the list of attendees. Because of that,
the memory associated with the attendee would never be freed. This patch
frees the memory if no e-mail address is provided.
........
Merged revisions 361606 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 361607 from http://svn.asterisk.org/svn/asterisk/branches/10
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@361608 65c4cc65-6c06-0410-ace0-fbb531ad65f3
https://origsvn.digium.com/svn/asterisk/branches/1.8
........
r287269 | pitel | 2010-09-17 10:37:49 +0200 (Pá, 17 zář 2010) | 8 lines
Support for HTTP redirects in calendar's URL
libneon does not support HTTP redirects (3xx responses) by default. You must tell it to follow them.
Also, another little unsigned int fix.
(closes issue #17776)
Review: https://reviewboard.asterisk.org/r/921/
........
r287270 | pitel | 2010-09-17 10:42:37 +0200 (Pá, 17 zář 2010) | 6 lines
Asterisk crashing because of double free when EWS request fails
The free is done later in code. I think ast_free() should have built in checks for double free.
(closes issue #17782)
........
r287271 | pitel | 2010-09-17 10:44:28 +0200 (Pá, 17 zář 2010) | 6 lines
Events are visible after they were removed from EWS calendar
Because we must merge calendar even when it's empty.
(closes issue #17786)
........
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@287272 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This uses a modified version of pabelanger's patch that checks for NTLM support
instead, which was added in 0.29.0 which is what is required for
res_calendar_ews.
(closes issue #17391)
Reported by: loloski
Patches:
issue17391.patch.v2 uploaded by pabelanger (license 224)
Tested by: twilson
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@265793 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This ensures cross-platform compatibility, even among Linux distributions,
which don't always put headers in the same place.
(closes issue #17391)
Reported by: loloski
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@265747 65c4cc65-6c06-0410-ace0-fbb531ad65f3