Merge branch 'maint'

* maint:
  Update release notes for 1.6.0.3
  checkout: Do not show local changes when in quiet mode
  for-each-ref: Fix --format=%(subject) for log message without newlines
  git-stash.sh: don't default to refs/stash if invalid ref supplied
  maint: check return of split_cmdline to avoid bad config strings
This commit is contained in:
Shawn O. Pearce
2008-09-25 08:27:53 -07:00
7 changed files with 49 additions and 6 deletions

View File

@ -321,8 +321,8 @@ static const char *find_wholine(const char *who, int wholen, const char *buf, un
static const char *copy_line(const char *buf)
{
const char *eol = strchr(buf, '\n');
if (!eol)
return "";
if (!eol) // simulate strchrnul()
eol = buf + strlen(buf);
return xmemdupz(buf, eol - buf);
}