]> jfr.im git - solanum.git/blobdiff - ircd/ircd_parser.y
send: add sendto_one_multiline_* API
[solanum.git] / ircd / ircd_parser.y
index f07c3f9ae747e40db494cdf4a6d3ea84d57efbaf..4f6a592edf6ba47b61b5c8d720b6b68415565d24 100644 (file)
@@ -160,7 +160,7 @@ static void add_cur_list(int type, char *str, int number)
 
 %union {
        int             number;
-       char            string[BUFSIZE + 1];
+       char            string[1024];
        conf_parm_t *   conf_parm;
 }
 
@@ -170,7 +170,7 @@ static void add_cur_list(int type, char *str, int number)
 %token <number> NUMBER
 
 %type <string> qstring string
-%type <number> number timespec
+%type <number> number timespec unittimespec
 %type <conf_parm> oneitem single itemlist
 
 %start conf
@@ -242,6 +242,9 @@ single: oneitem
                        {
                                add_cur_list(CF_INT, 0, i);
                        }
+
+                       rb_free($1);
+                       rb_free($3);
                }
        }
        ;
@@ -291,7 +294,7 @@ loadmodule:
                 char *m_bn;
                 m_bn = rb_basename((char *) $2);
 
-                if (findmodule_byname(m_bn) == -1)
+                if (findmodule_byname(m_bn) == NULL)
                {
                    load_one_module($2, MAPI_ORIGIN_EXTENSION, 0);
                }
@@ -305,7 +308,7 @@ qstring: QSTRING { strcpy($$, $1); } ;
 string: STRING { strcpy($$, $1); } ;
 number: NUMBER { $$ = $1; } ;
 
-timespec:      number string
+unittimespec:  number string
                {
                        time_t t;
 
@@ -317,7 +320,13 @@ timespec:  number string
 
                        $$ = $1 * t;
                }
-               | timespec timespec
+               ;
+
+timespec: unittimespec
+               {
+                       $$ = $1;
+               }
+               | timespec unittimespec
                {
                        $$ = $1 + $2;
                }