Opened 10 years ago

Last modified 10 years ago

#3218 new defect

The read_write.* interface seems a bit off

Reported by: adrpo Owned by: somebody
Priority: high Milestone: Future
Component: Run-time Version: trunk
Keywords: Cc: mahge930, sjoelund.se

Description

read_write.c uses malloc instead of GC_malloc.
Do we really need this elaborate interface anymore?
Can't we just send MetaModelica values directly now?
This is afaik used only to send/receive data from external functions compiled as dlls during instantiation and probably during scripting.

Change History (4)

comment:1 Changed 10 years ago by sjoelund.se

I am unsure if you can send MM values directly; they cross dll boundaries.

comment:2 Changed 10 years ago by adrpo

Yes, but is our dll, or isn't?

comment:3 Changed 10 years ago by sjoelund.se

Yes, but directly after returning, we free the dll, right? Don't you then (on MSVC) lose the data you allocated, like strings?

comment:4 Changed 10 years ago by adrpo

We can do as we do now and when the dll returns we duplicate the data and free the dll, just with metamodelica values.

Note: See TracTickets for help on using tickets.