#501 SetLocal causes segfailt

v4.0
closed
5
2012-08-14
2008-03-05
No

SetLocal function crashes interpreter. Test it with:
rexx rexxtry "call setlocal"

Here is the backtrace:

0 RexxActivation::pushEnvironment (this=0x0, environment=0xb782e078) at ./kernel/runtime/RexxActivation.cpp:3485

3485 if (this->activation_context&TOP_LEVEL_CALL) {
(gdb) bt

0 RexxActivation::pushEnvironment (this=0x0, environment=0xb782e078) at ./kernel/runtime/RexxActivation.cpp:3485

1 0xb7ef35c6 in REXX_PUSH_ENVIRONMENT (environment=0xb782e078) at ./kernel/runtime/RexxNativeActivation.cpp:1502

2 0xb7eca763 in sysSetLocal_m (self=0xb781d510) at ./kernel/platform/unix/ExternalFunctions.cpp:163

3 0xb7eca7ad in sysSetLocal (a=0xbfd95a98) at ./kernel/platform/unix/ExternalFunctions.cpp:153

4 0xb7ef500d in RexxNativeActivation::run (this=0xb782e010, _receiver=0xb781d510, _msgname=0xb782df48, _argcount=0,

_arglist=0xb7ae9164, resultObj=@0xbfd95c24) at ./kernel/runtime/RexxNativeActivation.cpp:404

5 0xb7ef59fc in RexxNativeCode::run (this=0xb775c7d8, activity=0xb781d7b8, method=0xb775ad90, receiver=0xb781d510,

messageName=0xb782df48, count=0, argPtr=0xb7ae9164, result=@0xbfd95c24) at ./kernel/runtime/RexxNativeCode.cpp:209

6 0xb7e81085 in BaseCode::call (this=0xb775c7d8, activity=0xb781d7b8, method=0xb775ad90, receiver=0xb781d510, msgname=0xb782df48,

arguments=0xb7ae9164, argcount=0, ct=0xb780b4d0, env=0x0, context=32, result=@0xbfd95c24)
at ./kernel/classes/MethodClass.cpp:633

7 0xb7e8233c in RexxMethod::call (this=0xb775ad90, activity=0xb781d7b8, receiver=0xb781d510, msgname=0xb782df48,

argPtr=0xb7ae9164, argcount=0, calltype=0xb780b4d0, environment=0x0, context=32, result=@0xbfd95c24)
at ./kernel/classes/MethodClass.cpp:147

8 0xb7ed817f in RexxActivation::externalCall (this=0xb781d510, target=0xb782df48, _argcount=0, _stack=0xb781d5bc,

calltype=0xb780b4d0, resultObj=@0xbfd95c24) at ./kernel/runtime/RexxActivation.cpp:2251

9 0xb7eab850 in RexxInstructionCall::execute (this=0xb782df90, context=0xb781d510, stack=0xb781d5bc)

at ./kernel/instructions/CallInstruction.cpp:256

10 0xb7edba0c in RexxActivation::run (this=0xb781d510, _receiver=0x0, msgname=0x0, _arglist=0xb7ae9038, _argcount=0, start=0x0,

resultObj=@0xbfd95ca4) at ./kernel/runtime/RexxActivation.cpp:393

11 0xb7edcafc in RexxActivation::interpret (this=0xb781b9d8, codestring=0xb782c8f8) at ./kernel/runtime/RexxActivation.cpp:1986

12 0xb7eb00ab in RexxInstructionInterpret::execute (this=0xb7826900, context=0xb781b9d8, stack=0xb781ba84)

at ./kernel/instructions/InterpretInstruction.cpp:80

13 0xb7edba0c in RexxActivation::run (this=0xb781b9d8, _receiver=0x0, msgname=0x0, _arglist=0xb7ae9038, _argcount=0,

start=0xb7824d30, resultObj=@0xbfd95d94) at ./kernel/runtime/RexxActivation.cpp:393

14 0xb7edc381 in RexxActivation::internalCall (this=0xb781b630, target=0xb7824d30, _argcount=0, _stack=0xb781b6dc,

returnObject=@0xbfd95d94) at ./kernel/runtime/RexxActivation.cpp:2495

15 0xb7eab89e in RexxInstructionCall::execute (this=0xb78209c0, context=0xb781b630, stack=0xb781b6dc)

at ./kernel/instructions/CallInstruction.cpp:246

16 0xb7edba0c in RexxActivation::run (this=0xb781b630, _receiver=0x0, msgname=0xb780b290, _arglist=0xb781ddf8, _argcount=1,

start=0x0, resultObj=@0xbfd95ef8) at ./kernel/runtime/RexxActivation.cpp:393

17 0xb7ee6629 in RexxCode::call (this=0xb782c0e8, activity=0xb781d7b8, method=0xb782c160, receiver=0x0, msgname=0xb780b290,

argPtr=0xb781ddf8, argcount=1, calltype=0xb7766e40, environment=0xb782c130, context=16, result=@0xbfd95ef8)
at ./kernel/runtime/RexxCode.cpp:99

18 0xb7e8233c in RexxMethod::call (this=0xb782c160, activity=0xb781d7b8, receiver=0x0, msgname=0xb780b290, argPtr=0xb781ddf8,

argcount=1, calltype=0xb7766e40, environment=0xb782c130, context=16, result=@0xbfd95ef8) at ./kernel/classes/MethodClass.cpp:147

19 0xb7e82417 in RexxMethod::runProgram (this=0xb782c110, activity=0xb781d7b8, calltype=0xb7766e40, environment=0xb782c130,

arguments=0xb781ddf8, argCount=1, result=@0xbfd95ef8) at ./kernel/classes/MethodClass.cpp:164

20 0xb7f04804 in RexxStartDispatcher::run (this=0xbfd95fe8) at ./kernel/runtime/RexxStartDispatcher.cpp:161

21 0xb7ef4434 in RexxNativeActivation::run (this=0xb781dd08, dispatcher=@0xbfd95fe8)

at ./kernel/runtime/RexxNativeActivation.cpp:549

22 0xb7ee16db in RexxActivity::run (this=0xb781d7b8, target=@0xbfd95fe8) at ./kernel/runtime/RexxActivity.cpp:2800

23 0xb7f04b35 in ActivityDispatcher::invoke (this=0xbfd95fe8) at ./kernel/runtime/ActivityDispatcher.cpp:95

24 0xb7ef6e87 in RexxStart (argcount=1, arglist=0xbfd980ac,

programname=0xbfd98cf2 "/home/moritz/dev/orexx_deb/oorexx-3.2.0/samples/rexxtry.rex", instore=0x0, envname=0x8048b28 "bash", 
calltype=0, exits=0x0, retcode=0xbfd980b6, result=0x0) at ./kernel/runtime/RexxStartup.cpp:173

25 0x080489bc in main (argc=3, argv=0xbfd98164) at ./platform/unix/rexx.cpp:168

26 0xb7b98450 in __libc_start_main () from /lib/i686/cmov/libc.so.6

27 0x080486a1 in _start ()

Here are more details:

0 RexxActivation::pushEnvironment (this=0x0, environment=0xb782e078) at ./kernel/runtime/RexxActivation.cpp:3485

No locals.

1 0xb7ef35c6 in REXX_PUSH_ENVIRONMENT (environment=0xb782e078) at ./kernel/runtime/RexxNativeActivation.cpp:1502

    context = {self = 0xb782e010, activity = 0xb781d7b8, instance = 0x0}
    activation = (class RexxActivation *) 0x0

2 0xb7eca763 in sysSetLocal_m (self=0xb781d510) at ./kernel/platform/unix/ExternalFunctions.cpp:163

    Current = (REXXOBJECT) 0xb782e078
    Retval = <value optimized out>

3 0xb7eca7ad in sysSetLocal (a=0xbfd95a98) at ./kernel/platform/unix/ExternalFunctions.cpp:153

No locals.

4 0xb7ef500d in RexxNativeActivation::run (this=0xb782e010, _receiver=0xb781d510, _msgname=0xb782df48, _argcount=0,

Discussion

  • dominic wise

    dominic wise - 2008-05-28

    Logged In: YES
    user_id=1382455
    Originator: NO

    Which version and platform exhibit this problem? Running under ooREXX 3.2 on Ubuntu 8.04 does not SEGFAULT

     
  • Moritz Hoffmann

    Moritz Hoffmann - 2008-05-28

    Logged In: YES
    user_id=1267170
    Originator: YES

    Just for completeness, this happened on the trunk. OS=Debian Testing, can't remember the SVN revision this happened on. As there was no progress in this field the bug is still valid.

     
  • dominic wise

    dominic wise - 2008-05-28

    Logged In: YES
    user_id=1382455
    Originator: NO

    Which version and platform exhibit this problem? Running under ooREXX 3.2 on Ubuntu 8.04 does not SEGFAULT

     
  • Rick McGuire

    Rick McGuire - 2008-10-06

    This no longer seems to happen.

     

Anonymous
Anonymous

Cancel  Add attachments