Excllent, works great now!<br>
<br>
Thanks!<br><br><div><span class="gmail_quote">On 4/13/06, <b class="gmail_sendername">Richard Lyman</b> <<a href="mailto:pchammer@dynx.net">pchammer@dynx.net</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Ron McCarthy wrote:<br>> Hello, I think this is the right list for this question!<br>><br>> I want to add some more amaflags to what is defined, so I thought I<br>> would just modify this function:<br>> /*! Converts AMA flag to printable string */
<br>> char *ast_cdr_flags2str(int flag)<br>> {<br>> switch(flag) {<br>> case AST_CDR_OMIT:<br>> return "OMIT";<br>> case AST_CDR_BILLING:<br>> return "BILLING";
<br>> case AST_CDR_DOCUMENTATION:<br>> return "DOCUMENTATION";<br>> case AST_CDR_NEWFLAG:<br>> return "NEWFLAG";<br>> }<br>> return "Unknown";
<br>> }<br>><br>> and<br>><br>> int ast_cdr_amaflags2int(const char *flag)<br>> {<br>> if (!strcasecmp(flag, "default"))<br>> return 0;<br>> if (!strcasecmp(flag, "omit"))
<br>> return AST_CDR_OMIT;<br>> if (!strcasecmp(flag, "billing"))<br>> return AST_CDR_BILLING;<br>> if (!strcasecmp(flag, "documentation"))<br>
>
return AST_CDR_DOCUMENTATION;<br>> if (!strcasecmp(flag, "newflag"))<br>> return AST_CDR_NEWFLAG;<br>> return -1;<br>> }<br>><br>> so i added the "newflag" part, which seemed to right to me (im not a c++
<br>> guru by any means), and now i get this when I try to make *,<br>><br>> cdr.c: In function `ast_cdr_flags2str':<br>> cdr.c:694: error: `AST_CDR_NEWFLAG' undeclared (first use in this function)<br>> cdr.c
:694: error: (Each undeclared identifier is reported only once<br>> cdr.c:694: error: for each function it appears in.)<br>> cdr.c: In function `ast_cdr_amaflags2int':<br>> cdr.c:799: error: `AST_CDR_NEWFLAG' undeclared (first use in this function)
<br>> gmake: *** [cdr.o] Error 1<br>><br>> any ideals?!!? I have grep'ed and search for anymore references of where<br>> this would go, im clueless!<br>><br>> Any help would be great!<br>><br>> Thanks
<br>> Ron<br>><br>><br>you forgot about asterisk/include/asterisk/cdr.h<br><br>/*! AMA Flags */<br>#define
AST_CDR_OMIT (1)<br>#define
AST_CDR_BILLING
(2)<br>#define
AST_CDR_DOCUMENTATION
(3)<br><br>you need to add<br><br>#define
AST_CDR_NEWFLAG
(4)<br><br><br><br><br><br><br>_______________________________________________<br>--Bandwidth and Colocation provided by <a href="http://Easynews.com">Easynews.com</a> --<br><br>asterisk-dev mailing list<br>To UNSUBSCRIBE or update options visit:
<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-dev">http://lists.digium.com/mailman/listinfo/asterisk-dev</a><br></blockquote></div><br>