Search found 112 matches

by softwarefailure
Thu Sep 14, 2023 9:30 pm
Forum: General Developer Support
Topic: Can't run the C runtime constructors and destructors manually
Replies: 7
Views: 49659

Re: Can't run the C runtime constructors and destructors manually

Who is responsible for the binutils on OS4 nowadays? I think it might be the best idea to contact him personally so that this can get fixed rather soonish. It's currently blocking me from release so I'd really need a solution for this.
by softwarefailure
Mon Aug 21, 2023 3:35 pm
Forum: General Developer Support
Topic: Can't run the C runtime constructors and destructors manually
Replies: 7
Views: 49659

Re: Can't run the C runtime constructors and destructors manually

afxgroup wrote: Sun Aug 20, 2023 8:39 pm It is still crashing in the .dtors because .dtors section is not null terminated.
Right, this makes sense. Thanks for checking! When can I expect a fix for this?
by softwarefailure
Thu Aug 17, 2023 7:46 pm
Forum: General Developer Support
Topic: Can't run the C runtime constructors and destructors manually
Replies: 7
Views: 49659

Re: Can't run the C runtime constructors and destructors manually


You have to use - O0 fno-aggressive-loop-optimizations or gcc will remove constructors and destructors


Check my original posting again. I've posted the build lines I'm using. As you can see from the build lines I'm not using any optimization options at all so passing -O0 fno-aggressive-loop ...
by softwarefailure
Sat Aug 12, 2023 8:50 pm
Forum: General Developer Support
Topic: Can't run the C runtime constructors and destructors manually
Replies: 7
Views: 49659

Can't run the C runtime constructors and destructors manually

I'm having major problems running the C runtime constructors/destructors manually in a program compiled using -nostartfiles and loaded via LoadSeg(). For purposes of illustration I have created two little sample programs that show the issue:

This is loader.c which loads the child program and calls ...
by softwarefailure
Mon Feb 08, 2021 3:29 pm
Forum: General Developer Support
Topic: Major memory leak in CreateNewProc()
Replies: 6
Views: 7883

Re: Major memory leak in CreateNewProc()

Thanks, I'm now using

Code: Select all

NP_Output, DupFileHandle(Output()),
NP_Input, DupFileHandle(Input()),
and no NP_CloseOutput/NP_CloseInput and the leak is gone. Thanks a lot!
by softwarefailure
Sat Feb 06, 2021 2:07 pm
Forum: General Developer Support
Topic: Major memory leak in CreateNewProc()
Replies: 6
Views: 7883

Major memory leak in CreateNewProc()

Check out the attached demo code. I think there's a major memory leak in CreateNewProc() when using these lines:


NP_Output, Output(),
NP_Input, Input(),
NP_CloseOutput, 0,
NP_CloseInput, 0,


without those lines, there is no leak. Also when just one thread is involved, there is no leak either, i ...
by softwarefailure
Sat Feb 06, 2021 2:01 pm
Forum: General Developer Support
Topic: How to free memory allocated by AddTrackable()
Replies: 8
Views: 23492

Re: How to free memory allocated by AddTrackable()

Thanks, this really helped me because from the documentation it's not entirely clear what's going on...
by softwarefailure
Sun Jan 31, 2021 2:57 pm
Forum: General Developer Support
Topic: How to free memory allocated by AddTrackable()
Replies: 8
Views: 23492

How to free memory allocated by AddTrackable()

I'm using AddTrackable() to track an object that should be destroyed when the task is removed. That works fine. When the task is removed, my destructor function is called and I can destroy the object.

But: Once my destructor function has been called and the task has been removed, how should I free ...
by softwarefailure
Thu Sep 24, 2020 7:58 pm
Forum: General Developer Support
Topic: OpenElfTags() - free memory
Replies: 1
Views: 4975

OpenElfTags() - free memory

When using OET_MemoryAddr with OpenElfTags(): Can I free the memory as soon as OpenElfTags() succeeds or do I have to keep the buffer until I call CloseElfTags()?
by softwarefailure
Sun Jun 21, 2020 8:47 pm
Forum: Platform: AmigaOne XE and MicroA1-C
Topic: MicroA1 dying :(
Replies: 11
Views: 48218

Re: MicroA1 dying :(

Someone from a different forum suggested replacing the battery and that indeed did the trick... now it's working again! Embarassing, but I didn't think of the battery! I still find it strange though that an empty battery causes a loss of the VGA signal. I'd expect U-Boot settings and system clock ...