Summary: | ASTERISK-15134: [patch] issues in processing "Action: Events" eventmask | ||
Reporter: | Vitezslav Novy (vnovy) | Labels: | |
Date Opened: | 2009-11-13 06:32:02.000-0600 | Date Closed: | 2010-01-08 19:30:54.000-0600 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Core/ManagerInterface |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) manager.c.patch | |
Description: | 1/ Incorrect check if eventmask is number in function strings_to_mask 2/ "Action: events" with "eventmask: on" returns no answer. When "eventmask: on" all eventmask values in perms structure are ORed including "all" with value -1, so function strings_to_mask returns -1 as current mask. This value is interpreted as error by action_events function and no response is sent 3/ "Action: events" with "eventmask: all" returns no answer. "all" is in list of valid eventmask values, but value -1 causes same problem as in 2/ ****** ADDITIONAL INFORMATION ****** @@ -373,7 +373,7 @@ { EVENT_FLAG_CDR, "cdr" }, { EVENT_FLAG_DIALPLAN, "dialplan" }, { EVENT_FLAG_ORIGINATE, "originate" }, - { -1, "all" }, + { 0x7fff, "all" }, { 0, "none" }, }; @@ -448,7 +448,7 @@ for (p = string; *p; p++) if (*p < '0' || *p > '9') break; - if (!p) /* all digits */ + if (!*p) /* all digits */ return atoi(string); if (ast_false(string)) return 0; | ||
Comments: | By: Leif Madsen (lmadsen) 2009-11-13 07:45:31.000-0600 Would you mind submitted that patch as a unified diff and attaching it to this issue? Thanks! By: Vitezslav Novy (vnovy) 2009-11-13 09:02:11.000-0600 Patch attached, I hope format is Ok By: Digium Subversion (svnbot) 2010-01-08 18:57:59.000-0600 Repository: asterisk Revision: 238915 U branches/1.4/main/manager.c ------------------------------------------------------------------------ r238915 | tilghman | 2010-01-08 18:57:59 -0600 (Fri, 08 Jan 2010) | 6 lines -1 is interpreted as an error, intead of the maximum mask. (closes issue ASTERISK-15134) Reported by: vnovy Patches: manager.c.patch uploaded by vnovy (license 922) ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=238915 By: Digium Subversion (svnbot) 2010-01-08 19:08:05.000-0600 Repository: asterisk Revision: 238916 _U trunk/ U trunk/main/manager.c ------------------------------------------------------------------------ r238916 | tilghman | 2010-01-08 19:08:05 -0600 (Fri, 08 Jan 2010) | 13 lines Merged revisions 238915 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r238915 | tilghman | 2010-01-08 18:57:58 -0600 (Fri, 08 Jan 2010) | 6 lines -1 is interpreted as an error, intead of the maximum mask. (closes issue ASTERISK-15134) Reported by: vnovy Patches: manager.c.patch uploaded by vnovy (license 922) ........ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=238916 By: Digium Subversion (svnbot) 2010-01-08 19:27:36.000-0600 Repository: asterisk Revision: 238968 _U branches/1.6.0/ U branches/1.6.0/main/manager.c ------------------------------------------------------------------------ r238968 | tilghman | 2010-01-08 19:27:35 -0600 (Fri, 08 Jan 2010) | 20 lines Merged revisions 238916 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r238916 | tilghman | 2010-01-08 19:08:04 -0600 (Fri, 08 Jan 2010) | 13 lines Merged revisions 238915 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r238915 | tilghman | 2010-01-08 18:57:58 -0600 (Fri, 08 Jan 2010) | 6 lines -1 is interpreted as an error, intead of the maximum mask. (closes issue ASTERISK-15134) Reported by: vnovy Patches: manager.c.patch uploaded by vnovy (license 922) ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=238968 By: Digium Subversion (svnbot) 2010-01-08 19:30:39.000-0600 Repository: asterisk Revision: 238983 _U branches/1.6.1/ U branches/1.6.1/main/manager.c ------------------------------------------------------------------------ r238983 | tilghman | 2010-01-08 19:30:38 -0600 (Fri, 08 Jan 2010) | 20 lines Merged revisions 238916 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r238916 | tilghman | 2010-01-08 19:08:04 -0600 (Fri, 08 Jan 2010) | 13 lines Merged revisions 238915 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r238915 | tilghman | 2010-01-08 18:57:58 -0600 (Fri, 08 Jan 2010) | 6 lines -1 is interpreted as an error, intead of the maximum mask. (closes issue ASTERISK-15134) Reported by: vnovy Patches: manager.c.patch uploaded by vnovy (license 922) ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=238983 By: Digium Subversion (svnbot) 2010-01-08 19:30:53.000-0600 Repository: asterisk Revision: 238985 _U branches/1.6.2/ U branches/1.6.2/main/manager.c ------------------------------------------------------------------------ r238985 | tilghman | 2010-01-08 19:30:53 -0600 (Fri, 08 Jan 2010) | 20 lines Merged revisions 238916 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r238916 | tilghman | 2010-01-08 19:08:04 -0600 (Fri, 08 Jan 2010) | 13 lines Merged revisions 238915 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r238915 | tilghman | 2010-01-08 18:57:58 -0600 (Fri, 08 Jan 2010) | 6 lines -1 is interpreted as an error, intead of the maximum mask. (closes issue ASTERISK-15134) Reported by: vnovy Patches: manager.c.patch uploaded by vnovy (license 922) ........ ................ ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=238985 |