One more:

4634.256135468:7fd44a3b6700: scriptExec: batch of 8 elements, active (nil), active[0]:1
4634.256153433:7fd44a3b6700:     SET .uptime =
4634.256191621:7fd44a3b6700:       var '$uptime'
4634.256236560:7fd44a3b6700:     END SET
4634.256272698:7fd44a3b6700: eval expr 0x25b7560, type 'V[86]'
Segmentation fault (core dumped)

(gdb) bt
#0  0x00007fd44b8aa3b1 in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#1 0x00007fd44b967d90 in __vsnprintf_chk () from /lib/x86_64-linux-gnu/libc.so.6 #2 0x0000000000437773 in vsnprintf (__ap=0x7fd44a3ad958, __fmt=<optimized out>, __n=32768, __s=0x7fd44a3ad970 "rainerscript: var 160:ype 'V[86]'\n") at /usr/include/x86_64-linux-gnu/bits/stdio2.h:78
#3  dbgprintf (fmt=<optimized out>) at debug.c:1018
#4 0x000000000041f0f5 in evalVar (ret=0x7fd44a3b5b00, usrptr=<optimized out>, var=0x25b7560) at rainerscript.c:1625 #5 cnfexprEval (expr=0x25b7560, ret=0x7fd44a3b5b00, usrptr=<optimized out>) at rainerscript.c:2064

This is for all non-time properties.


--
Pavel Levshin


23.10.2013 22:45, Pavel Levshin:
It segfaults here:

    set $!var1 = $$now;


#0  getNOW (eNow=NOW_NOW, t=0x0) at msg.c:2476
#1 0x000000000043086a in MsgGetProp (pMsg=0xd65bd0, pTpe=0x0, pProp=<optimized out>, pPropLen=0x7fc33866da78,
    pbMustBeFreed=0x7fc33866da7e, ttNow=<optimized out>) at msg.c:2932
#2 0x000000000041e65f in evalVar (ret=0x7fc33866db00, usrptr=0xd65bd0, var=0xd65390) at rainerscript.c:1623

because ttNow should not be NULL when getting time-based properties.


--
Pavel Levshin


23.10.2013 20:46, Rainer Gerhards:
Hi all,

I think most of the refactoring work is done. If someone would like to play
a little bit with the code, it is available in the master-var-refactor
branch:

http://git.adiscon.com/?p=rsyslog.git;a=shortlog;h=refs/heads/master-var-refactor

Actually, it would be cool to get some feedback and bug reports ;)

Var handling functions are unified now, so $!xx works. String templates now support bot %!xx% and the traditional %$!xx%. Along the refactoring, I also unified a lot of functions and string handling libs, which will also result in better performance of that system. Finally, I fixed some bugs that were
hiding in the local (and global) namespace handling.

I am pretty sure I introduced new bugs. Doc still needs to be updated, and
I may have overlooked some places. Will check that tomorrow.

Again, feel motivated to break the code (Note: Pavel's patch is *not* yet
applied).

Rainer
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE THAT.

_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE THAT.

_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.

Reply via email to