X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/217099990c2665d18d352c60058106da9a014ab8..2f8f7c77d3daef7fd1715752d3f739b55a0015d7:/src/univ/textctrl.cpp diff --git a/src/univ/textctrl.cpp b/src/univ/textctrl.cpp index 9d5bdc38c3..09bf799a15 100644 --- a/src/univ/textctrl.cpp +++ b/src/univ/textctrl.cpp @@ -1736,6 +1736,8 @@ wxTextCoord wxTextCtrl::GetRowsPerLine(wxTextCoord line) const wxTextCoord wxTextCtrl::GetRowCount() const { wxTextCoord count = GetLineCount(); + if (count == 0) + return 0; if ( WrapLines() ) { count = GetFirstRowOfLine(count - 1) +