Closed GoogleCodeExporter closed 8 years ago
Follow up here:
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=30584
48
Seems to me that the problem is in the src\Utils\Hooks.cpp code, in bool
CHooks::Save() , where the defined hooks are stored back into the registry key
, the code that glues together the string to store looks like:
for (hookiterator it = begin(); it != end(); ++it)
{
strhooks += GetHookTypeString(it->first.htype);
strhooks += '\n';
strhooks += it->first.path.GetWinPathString();
strhooks += '\n';
strhooks += it->second.commandline;
strhooks += '\n';
strhooks += (it->second.bWait ? _T("true") : _T("false"));
strhooks += '\n';
strhooks += (it->second.bShow ? _T("show") : _T("hide"));
strhooks += '\n';
if (it->second.bEnforce)
strhooks += _T("enforce\n");
}
Those last two lines, that tack on the 'enforce\n' bit ... well, if bEnforce
isn't true, then no '\n' delimiter will be tacked on, and then later during the
read in, if there are more than one hooks stored in the registry string,
they'll be fouled up via an off-by-one style error. Perhaps something like:
strhooks += (it->second.bEnforce ? _T("enforce") : _T("disregard"));
strhooks += '\n';
would fix this ... Hope that is useful...
Original comment by tortoisesvn
on 19 Jun 2013 at 5:53
This issue was closed by revision r24419.
Original comment by tortoisesvn
on 19 Jun 2013 at 6:11
This issue was closed by revision r24422.
Original comment by tortoisesvn
on 19 Jun 2013 at 7:26
Original issue reported on code.google.com by
tortoisesvn
on 19 Jun 2013 at 5:52Attachments: