I made a debug on MacOs with Xcode (after fixing the compile error).

rexximage(30751,0x10075b380) malloc: *** error for object 0x101801800: pointer being freed was not allocated


#0 0x00007fff7b350b66 in __pthread_kill ()
#1 0x00000001007540f0 in pthread_kill ()
#2 0x00007fff7b2ac1ae in abort ()
#3 0x00007fff7b3aa822 in free ()
#4 0x00000001003ccf2c in FileNameBuffer::~FileNameBuffer() at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/memory/FileNameBuffer.hpp:60
#5 0x00000001003ca505 in FileNameBuffer::~FileNameBuffer() at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/memory/FileNameBuffer.hpp:57
#6 0x000000010044c10d in InterpreterInstance::resolveProgramName(RexxString*, RexxString*, RexxString*) at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/runtime/InterpreterInstance.cpp:1085
#7 0x00000001003e3831 in Activity::resolveProgramName(RexxString*, RexxString*, RexxString*) at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/concurrency/Activity.cpp:3400
#8 0x00000001003c7b79 in MemoryObject::createImage() at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/memory/Setup.cpp:1700
#9 0x00000001003c80cd in MemoryObject::initialize(bool) at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/memory/RexxMemory.cpp:200
#10 0x00000001004484a9 in Interpreter::startInterpreter(Interpreter::InterpreterStartupMode) at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/runtime/Interpreter.cpp:155
#11 0x0000000100371beb in ::RexxCreateInterpreterImage() at /local/rexx/oorexx/official/sandbox/rick/rexxutil/interpreter/api/InterpreterAPI.cpp:93
#12 0x0000000100001f84 in main at /local/rexx/oorexx/official/sandbox/rick/rexxutil/utilities/rexximage/rexximage.cpp:44
#13 0x00007fff7b200015 in start ()

Then during further investigation, I noticed other  things to fix (probably already fixed locally in your sandbox)
FileNameBuffer.hpp : 
replace memcmp by memcpy where appropriate (2 occurrences)

unix/SysInterpreterInstance.hpp :
replace ‘;’ by ‘:’ where appropriate (2 occurrences)

After fixing that and adding the copy constructor & operator, I was able to build your sandbox, and the resulting rexx executable is working.

To check if the copy constructor & operator is really needed, you can declare them private.
You will have some compilation errors, it’s a good way to see where the compiler creates temporary objects for FileNameBuffer

Attachment: changes_applied.patch
Description: Binary data



On 2 Feb 2019, at 11:44, Rick McGuire <object.r...@gmail.com> wrote:

oops, I still had some uncommitted code. 

Rick

On Fri, Feb 1, 2019 at 7:57 PM Enrico Sorichetti via Oorexx-devel <oorexx-devel@lists.sourceforge.net> wrote:
Hi Rick,
I gave it a try with 



svn info
Path: .
Working Copy Root Path: /opt/oorexx.rick
Relative URL: ^/sandbox/rick/rexxutil
Repository UUID: 0b6cbdbe-3aab-466e-b73a-abd511dda0a2
Revision: 11703
Node Kind: directory
Schedule: normal
Last Changed Author: bigrixx
Last Changed Rev: 11702
Last Changed Date: 2019-01-31 22:25:51 +0000 (Thu, 31 Jan 2019)


Unfortunately I get 

/opt/oorexx.rick/interpreter/platform/unix/SysRexxUtil.cpp: In function '_RexxObjectPtr* SysGetFileDateTime_impl(RexxCallContext*, CSTRING, CSTRING)':
/opt/oorexx.rick/interpreter/platform/unix/SysRexxUtil.cpp:1693:102: error: 'echoOpt' was not declared in this scope
                 invalidOptionException(context, "SysGetFileDateTime", "time selector", "'A' or 'W'", echoOpt);


Enrico


On 2 Feb 2019, at 00:39, Rick McGuire <object.r...@gmail.com> wrote:

For my rexxutil sandbox version, I'm able to get a clean build on Windows, but on Linux, I get a crash running rexximage. I've tried debugging this using ddd, but it doesn't really give my any useful information. I'd really appreciate any assistance you can provide.

Rick
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to