Andy Levy wrote:
My own pre-commit hook has the same flaw. I just haven't gotten around to fixing it because I have few enough users that it's easier to just tell them "don't do that" - and I haven't been given the time to redo my hooks in a better language.
If that helps, you can strip "forbidden" characters like that:

set LOGMSG=%LOGMSG:>=_%
set LOGMSG=%LOGMSG:'=_%
set LOGMSG=%LOGMSG:"=_%


but the LOGMSG variable must not be empty for it to work. So if you extract the log message from the transaction, be sure to always put at least one character into LOGMSG and adjust your length checks accordingly.
A full example is here:

http://svnwintools.tigris.org/source/browse/*checkout*/svnwintools/trunk/sources/SVNHookScripts/check-empty-log.bat?revision=HEAD&content-type=text%2Fplain

Reply via email to