Summary: | ASTERISK-06817: [patch] Voicemail crashes Asterisk if user chooses to prepend when forwarding. | ||
Reporter: | zebble (zebble) | Labels: | |
Date Opened: | 2006-04-19 23:25:04 | Date Closed: | 2006-04-26 14:24:13 |
Priority: | Critical | Regression? | No |
Status: | Closed/Complete | Components: | Applications/app_voicemail |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ||
Description: | If a user chooses to prepend a message while forwarding, Asterisk segfaults on ast_readfile. ****** ADDITIONAL INFORMATION ****** The fix: Add check for bfile before closing in file.c. This fixes the underlying segfault, but not the problem in app_voicemail.c. app_voicemail.c fix is below: file.c Line 849: if (bfile) fclose(bfile); app_voicemail.c Line 3456: if ((receiver = find_user(NULL, context, s)) && strcmp(s,sender->mailbox)) { This prevents two problems. If the user prepends and forwards it to themselves (why would they? who knows!), the original files are overwritten, so ast_fileread fails when it can't find the original file (file.c change fixes that). This causes the segfault, and other conditions may cause it, which is why I made the change. The second change fixes the original problem, and prevents the user from forwarding to their own mailbox. I didn't bother adding a diff, as these are fairly minor changes. | ||
Comments: | By: Matt O'Gorman (mogorman) 2006-04-26 14:24:06 voicemail fix commited in 1.2 and trunk commits 22596 and 22597. I don't see why you would need the file.c commits in either branch. |