07-20-2013, 01:52 PM | #1 |
Human being with feelings
Join Date: Jul 2013
Posts: 1
|
Minor bug causes INI-file to grow
On Windows, every time LICEcap 1.23 is closed, the settings in the "%APPDATA%\licecap.ini" file are updated in such a way that yet another linefeed character is introduced at the end of the "wnd_r=…" row. This is not visible in Notepad (as it doesn't recognize linefeeds alone), but can be seen in other text editors (like Notepad++). Note that although the INI-file uses CR/LF-pairs as a new line indicator, the appended character is just a single LF (one more every time).
|
08-04-2013, 01:17 AM | #2 |
Human being with feelings
Join Date: May 2012
Posts: 1,216
|
Confirmed !
(My notepad shows the linefeed character.) |
09-11-2013, 03:21 AM | #3 |
Human being with feelings
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
|
There is a "\n" in a sprintf() format string that shouldn't be there, i.e.:
Code:
diff --git a/licecap_ui.cpp b/licecap_ui.cpp index 35dae18..ed71b64 100644 --- a/licecap_ui.cpp +++ b/licecap_ui.cpp @@ -759,7 +759,7 @@ static WDL_DLGRET liceCapMainProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM char buf[1024]; RECT r; GetWindowRect(hwndDlg,&r); - sprintf(buf,"%d %d %d %d\n",r.left,r.top,r.right,r.bottom); + sprintf(buf,"%d %d %d %d",r.left,r.top,r.right,r.bottom); WritePrivateProfileString("licecap","wnd_r",buf,g_ini_file.Get()); sprintf(buf, "%d", g_max_fps); WritePrivateProfileString("licecap","maxfps",buf,g_ini_file.Get()); |
09-12-2013, 10:09 AM | #4 |
Administrator
Join Date: Jan 2005
Location: NYC
Posts: 15,721
|
oops. heh.
|
Thread Tools | |
Display Modes | |
|
|