Opened 11 years ago

Closed 11 years ago

#2311 closed defect (fixed)

XML Editor can try to divide by zero

Reported by: jng Owned by: jng
Priority: low Milestone: Maestro-5.0
Component: Maestro Version:
Severity: trivial Keywords:
Cc: External ID:

Description

When pulling on the XML editor scrollbar, it can try to divide by zero (see attached screenshot)

Attachments (2)

Capture.PNG (61.3 KB ) - added by jng 11 years ago.
2311.patch (923 bytes ) - added by jng 11 years ago.
Avoid entering divide by zero code

Download all attachments as: .zip

Change History (4)

by jng, 11 years ago

Attachment: Capture.PNG added

comment:1 by jng, 11 years ago

Attempting to then mouse over the "X" area then throws this exception

System.DivideByZeroException: Attempted to divide by zero.
   at ICSharpCode.TextEditor.TextView.GetLogicalColumnInternal(Graphics g, LineSegment line, Int32 start, Int32 end, Int32& drawingPos, Int32 targetVisualPosX)
   at ICSharpCode.TextEditor.TextView.GetLogicalColumn(Int32 lineNumber, Int32 visualPosX, FoldMarker& inFoldMarker)
   at ICSharpCode.TextEditor.TextArea.OnMouseMove(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseMove(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

by jng, 11 years ago

Attachment: 2311.patch added

Avoid entering divide by zero code

comment:2 by jng, 11 years ago

Resolution: fixed
Status: newclosed

Fixed r7680

Note: See TracTickets for help on using tickets.