#54 CNick::GetPermStr() causes ZNC to close

closed-fixed
Psychon
Engine (43)
5
2009-04-16
2009-04-15
Steven
No

Using ZNC 0.68... When creating my own C++ module and using the following function, as an example:

virtual EModRet OnChanMsg(CNick& Nick, CChan& Channel, CString& sMessage) {
PutModule("Nick.GetNick() = " + Nick.GetNick());
PutModule("Channel.GetName() = " + Channel.GetName());
PutModule("Nick.GetPermStr() = " + Nick.GetPermStr());
PutModule("Channel.GetPermStr() = " + Channel.GetPermStr());
return CONTINUE;
}

causes ZNC to close seemingly gracefully, as the defined exit message is shown when it closes.

No errors or warnings reported during znc-buildmod.

If I comment out the following lines:

PutModule("Nick.GetPermStr() = " + Nick.GetPermStr());
PutModule("Channel.GetPermStr() = " + Channel.GetPermStr());

ZNC doesn't close.

Discussion

  • Nobody/Anonymous

    So... Where's the bug? Oh and I have no idea why this kills znc.
    Which of the two remaining lines is the offending one? Does either of them kill ZNC?

     
  • Steven

    Steven - 2009-04-16

    Sorry, I don't know where exactly the bug resides. I lodged it as a bug as I assume it's not by design that it shuts down gracefully when the function is invoked.

    The shutdown occurs with either statement, if I recall. I believe CChan::GetPermStr() references CNick::GetPermStr().

     
  • Psychon

    Psychon - 2009-04-16
    • labels: 707556 --> Engine
    • assigned_to: prozacx --> psychon
    • status: open --> closed-fixed
     
  • Psychon

    Psychon - 2009-04-16

    Fixed in r1491. Thanks for the bug report.
    Oh and nope, GetPermStr() wont return anything useful.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks