[Solved] Possible malloc() problem SRCPD

Post Reply
Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

[Solved] Possible malloc() problem SRCPD

Post by Richard-TX » 04.07.2013, 16:29

Rob and Lothar,

I think I found a malloc issue...well maybe it a free() issue.

What happens is with each srcp connection to Rocrail the amount of memory used by Rocrail grows. According to what I am seeing the amount of memory used is +12k per connection. After 100 connections the amount of memory used by rocrail.exe is an additional 120k.

To duplicate the issue start Rocrail on a PC and configure it so that it will listen for incoming srcp connections.

Then run a script that opens a srcp connection to Rocrail, issues some sort of srcp command and then closes. The srcp command I used was to set a fb device.

Open a win taskmanager , select performance and watch the memory allocated by rocrail.exe grow with each run of the script..

I discovered this as part of my regression testing.

This occurs on version 5501
Attachments
roctest.txt
This is a python script that opens a connection to a scrp server and sets a FB device and then closes the TCP connection.

IP address is hardcoded.

usage is as follows:
scriptname -a <fb addr> -p <0 or 1)
(1.3 KiB) Downloaded 21 times
rocrail.ini
(2.64 KiB) Downloaded 43 times
plan.xml
(34.7 KiB) Downloaded 43 times
Last edited by Richard-TX on 04.07.2013, 16:42, edited 3 times in total.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Post by Richard-TX » 04.07.2013, 16:29

here is the trace file.

I think this is a low priority bug. It generally takes a few thousand sessions before windows complains about being low on memory and if the connections persist, rocrail will eventually stop.
Attachments
rocview.008.zip
(3.47 KiB) Downloaded 41 times

rjversluis
Site Admin
Posts: 39320
Joined: 10.04.2006, 08:48
Location: Speyer, Germany
Contact:

Post by rjversluis » 04.07.2013, 18:56

Hi Richard,

tnx for reporting.
Should be fixed in 5508.

Richard-TX
Posts: 1320
Joined: 10.07.2012, 04:00
Location: Texas, USA
Contact:

Post by Richard-TX » 05.07.2013, 13:25

And indeed it is fixed.

Thanks Rob!!


:well_done: :goodjob:

Post Reply

Return to “srcp”