Merge branch 'maint' into next

debian
Theodore Ts'o 2015-07-22 00:18:14 -04:00
commit 956b0f18a5
2 changed files with 6 additions and 1 deletions

View File

@ -97,6 +97,11 @@ void do_extent_open(int argc, char *argv[])
orig_prompt = ss_get_prompt(sci_idx);
extent_prompt = malloc(strlen(orig_prompt) + 32);
if (extent_prompt == NULL) {
com_err(argv[1], retval, "out of memory");
return;
}
strcpy(extent_prompt, orig_prompt);
cp = strchr(extent_prompt, ':');
if (cp)

View File

@ -170,7 +170,7 @@ static void fix_symlink (char *path, dev_t my_dev)
struct stat stbuf, lstbuf;
int c, fix_abs = 0, fix_messy = 0, fix_long = 0;
if ((c = readlink(path, lpath, sizeof(lpath))) == -1) {
if ((c = readlink(path, lpath, sizeof(lpath) - 1)) == -1) {
perror(path);
return;
}