Bug 416257 - Get a TCF error for the service LineNumbers
Summary: Get a TCF error for the service LineNumbers
Status: RESOLVED FIXED
Alias: None
Product: TCF
Classification: Tools
Component: Agent (show other bugs)
Version: 1.2   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 1.2   Edit
Assignee: Project Inbox CLA
QA Contact: Eugene Tarassov CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-30 11:30 EDT by Benoit Perrin CLA
Modified: 2014-02-25 05:50 EST (History)
0 users

See Also:


Attachments
test application (178.92 KB, application/octet-stream)
2013-08-30 11:30 EDT, Benoit Perrin CLA
eugene: iplog-
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benoit Perrin CLA 2013-08-30 11:30:36 EDT
Created attachment 235038 [details]
test application

I am using the service to recover all the sources and line mapping for the text segment of the attached test application.
The agent returns an error:

2013-08-30 17:18:40,207 : ---> C 25 LineNumbers mapToSource "P15713.15713" 134512640 134537216 
2013-08-30 17:18:40,208 : <--- R 25 None None {"Code":4,"Time":1377875920203,"Format":"Buffer overflow"} null 

In the agent, there is a hard coded limit of the possible number of code areas, set to 256. Why is there such a limit? For C++, there can be a lot more areas than 256 for a simple application.

Can this limit be removed? Or at least can the command mapToSource returns what it got so far + an error saying that there are more data? Or return the data with progress 'P' command replies?
Comment 1 Eugene Tarassov CLA 2013-08-30 14:44:24 EDT
We have to limit amount of returned data to protect the agent from misbehaving clients that ask for too much data and cause the agent to stall, or to crash on memory overflow.

I have changed the code to return what it got so far + "buffer overflow" error, and I've increased the buffer size. Now, if a client gets the error, it can re-request the rest of line data using end address of the last returned code area as new start address.

Fixed.
Thanks!