mirror of
https://github.com/znc/znc.git
synced 2026-08-08 09:52:55 +02:00
use newCONSTSUB for these
git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@314 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
+9
-4
@@ -747,10 +747,15 @@ bool CModPerl::OnLoad( const CString & sArgs )
|
||||
// this sets up the eval CB that we call from here on out. this way we can grab the error produced
|
||||
SetupZNCScript();
|
||||
|
||||
Eval( "use constant CONTINUE => " + PString( CONTINUE ) + ";" );
|
||||
Eval( "use constant HALT => " + PString( HALT ) + ";" );
|
||||
Eval( "use constant HALTMODS => " + PString( HALTMODS ) + ";" );
|
||||
Eval( "use constant HALTCORE => " + PString( HALTCORE ) + ";" );
|
||||
HV *pZNCSpace = get_hv ( "ZNC::", TRUE);
|
||||
|
||||
if ( !pZNCSpace )
|
||||
return( false );
|
||||
|
||||
newCONSTSUB ( pZNCSpace, "CONTINUE", newSViv (CONTINUE) );
|
||||
newCONSTSUB ( pZNCSpace, "HALT", newSViv (HALT) );
|
||||
newCONSTSUB ( pZNCSpace, "HALTMODS", newSViv (HALTMODS) );
|
||||
newCONSTSUB ( pZNCSpace, "HALTCORE", newSViv (HALTCORE) );
|
||||
|
||||
if ( !sArgs.empty() )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user