[Bro] Escape sequences in BRO (\n)

Иван Раткин adh.2234 at gmail.com
Fri Aug 4 13:28:56 PDT 2017


Well, the printed line for this sample is:

First line\x0aSecond line\x0a



2017-08-04 20:31 GMT+03:00 Patrick P Murphy <pmurphy+bro at nrao.edu>:

> On Fri, 4 Aug 2017 17:04:07 +0300, <adh.2234 at gmail.com> said:
>
> >    local line = fmt("%s", "Hi \n all!");
> >    print line;
> >    will print the Hi \n all!
>
> Shouldn't the \n be in the format specifier?  Eg.,
>
>    local lines = fmt("%s\n%s\n", "First line", "Second line");
>
> I don't think C or perl or other shell scripts with printf-like
> capabilities would behave differently: the controls have to be in the
> format specifier, not the data.
>
>  - Pat
> _______________________________________________
> Bro mailing list
> bro at bro-ids.org
> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/bro
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/bro/attachments/20170804/2f168d60/attachment.html 


More information about the Bro mailing list