]> jfr.im git - solanum.git/blobdiff - ircd/ircd_lexer.l
whowas.c: store account name in whowas (#323)
[solanum.git] / ircd / ircd_lexer.l
index 99ce22cdd1dac336568e1b51a7ee0caa2721fdb6..0268341ac635e9ed97f8ba120e52068d400d5c38 100644 (file)
@@ -94,7 +94,7 @@ include   \.include{ws}(\<.*\>|\".*\")
                     }
                   else
                     {
-                      strcpy(yylval.string, yytext + 1);
+                      rb_strlcpy(yylval.string, yytext + 1, 1024);
                       if(yylval.string[yyleng-2] != '"')
                         ilog(L_MAIN, "Unterminated character string");
                       else
@@ -134,7 +134,7 @@ include   \.include{ws}(\<.*\>|\".*\")
 
 loadmodule     { return LOADMODULE; }
 {string}        {
-                 strcpy(yylval.string, yytext);
+                 rb_strlcpy(yylval.string, yytext, 1024);
                   yylval.string[yyleng] = '\0';
                   return STRING;
                 }
@@ -196,7 +196,7 @@ void cinclude(void)
       /* if its not found in PREFIX, look in IRCD_PATH_ETC */
       char fnamebuf[BUFSIZE];
 
-      snprintf(fnamebuf, sizeof(fnamebuf), "%s%c%s", ircd_paths[IRCD_PATH_ETC], RB_PATH_SEPARATOR, c);
+      snprintf(fnamebuf, sizeof(fnamebuf), "%s/%s", ircd_paths[IRCD_PATH_ETC], c);
       tmp_fbfile_in = fopen(fnamebuf, "r");
 
       /* wasnt found there either.. error. */