Skip to content

Commit 048b7c7

Browse files
committed
isEscaped fix for GCC error parsing in Console
- from lint report from Jocelyn Lagault - fallthrough case in AboutDialog2.cpp repaired to be more readable Signed-off-by: Dave Brotherstone <davegb@pobox.com>
1 parent e6dacb9 commit 048b7c7

2 files changed

Lines changed: 16 additions & 15 deletions

File tree

PythonScript/src/AboutDialog2.cpp

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -55,25 +55,23 @@ BOOL CALLBACK AboutDialog::run_dlgProc(HWND hWnd, UINT Message, WPARAM wParam, L
5555
}
5656

5757
case WM_COMMAND :
58-
{
59-
60-
61-
switch (wParam)
62-
{
63-
case IDOK :
64-
case IDCANCEL :
65-
display(FALSE);
66-
return TRUE;
58+
switch (wParam)
59+
{
60+
case IDOK :
61+
case IDCANCEL :
62+
display(FALSE);
63+
return TRUE;
6764

68-
default :
69-
break;
70-
}
71-
72-
}
65+
default :
66+
break;
67+
}
68+
return FALSE;
69+
7370
default:
7471
return FALSE;
7572
}
7673

74+
7775
}
7876

7977
void AboutDialog::init( HINSTANCE hInst, NppData& nppData )

PythonScript/src/ConsoleDialog.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -824,12 +824,15 @@ bool ConsoleDialog::parseGCCErrorLine(LineDetails *lineDetails)
824824
break;
825825
}
826826

827+
if (isEscaped)
828+
isEscaped = false;
829+
827830
if (lineDetails->line[pos] == '\\')
828831
isEscaped = true;
829832

830833
++pos;
831834

832-
isEscaped = false;
835+
833836
}
834837

835838
if (lineDetails->line[pos] == ':') // Found the colon for line no

0 commit comments

Comments
 (0)