Skip to content

Commit

Permalink
MinGW: Fix SEGV
Browse files Browse the repository at this point in the history
Running the following command in ./sakura_core causes SEGV:
```
sakura.exe StdAfx.h -MTYPE=js -M="Down();Up();Right();Left();ShowFunckey();ShowMiniMap();ShowTab();SelectAll();GoFileEnd();GoFileTop();ShowFunckey();ShowMiniMap();ShowTab();ExitAll();"
```

This fixes it.

Related:
sakura-editor#1363 (comment), sakura-editor#601, sakura-editor#1372
  • Loading branch information
k-takata committed Aug 24, 2020
1 parent 092fbd4 commit 6a7c8cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sakura_core/view/CEditView_Paint_Bracket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ bool CEditView::SearchBracket(
CLogicPoint ptPos;

m_pcEditDoc->m_cLayoutMgr.LayoutToLogic( ptLayout, &ptPos );
const wchar_t *cline = m_pcEditDoc->m_cDocLineMgr.GetLine(ptPos.GetY2())->GetDocLineStrWithEOL(&len);
const wchar_t *cline = CDocLine::GetDocLineStrWithEOL_Safe(m_pcEditDoc->m_cDocLineMgr.GetLine(ptPos.GetY2()), &len);

// Jun. 19, 2000 genta
if( cline == NULL ) // 最後の行に本文がない場合
Expand Down

0 comments on commit 6a7c8cd

Please sign in to comment.