bugDotGNU Portable.NET - Bugs: bug #13133, Stack overflow exception in...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #13133: Stack overflow exception in SetBoundsCore

Submitted by:  Heiko Weiss <brubbel>
Submitted on:  Fri 20 May 2005 10:02:11 AM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Tue 24 May 2005 04:36:01 AM UTC, comment #4:

@Erich

it's not a bug in my sample.
it works in DotNet, so it should work in DotGnu too.

Heiko Weiss <brubbel>
Project Member
Mon 23 May 2005 04:38:36 PM UTC, comment #3:

This bug has been fixed with patch #4037.
Just as a remark. You should always call base.SetBoundsCore if you override this function.
With this call you can specify the changed location or zize and avoid the endless loop.

Klaus Treichel <ktreichel>
Project Administrator
Mon 23 May 2005 03:19:32 PM UTC, comment #2:

It's problematic to have the following line in the overwritten SetBoundsCore method:

this.Height = 50;

Because this causes the endless recursion. IMO it's rather a bug in your example... How do other .net implementations handle it?

Erich Kitzmüller <ammoq>
Fri 20 May 2005 10:18:11 AM UTC, comment #1:

added sample to reproduce the bug.

Heiko Weiss <brubbel>
Project Member
Fri 20 May 2005 10:02:11 AM UTC, original submission:

if U override the SetBoundsCore method in Control.cs and U set e.G. the Height of the control, U get a stack overflow exception, because Control.cs calls SetBoundsCore again recursivly.

Control.cs must check if the value is changed and if no change was made, don't call SetBoundsCore again.

I just made a patch. See atachement.

Heiko Weiss <brubbel>
Project Member

 

Attached Files
file #2996:  Form1.cs added by brubbel (2KiB - text/plain - sample to reproduce the bug)
file #2995:  brubbel-050520.patch added by brubbel (2KiB - application/octet-stream - patch Control.cs)

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 4 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Mon 23 May 2005 04:38:36 PM UTCktreichelStatusNone=>Fixed
  Open/ClosedOpen=>Closed
Fri 20 May 2005 10:18:11 AM UTCbrubbelAttached File-=>Added Form1.cs, #2521
Fri 20 May 2005 10:02:12 AM UTCbrubbelAttached File-=>Added brubbel-050520.patch, #2520

Back to the top


Powered by Savane 3.1-cleanup1