mirror of https://github.com/vitalif/e2fsprogs
Merge branch 'maint' into next
commit
560080272f
|
@ -20,6 +20,8 @@
|
||||||
#include "e2fsck.h"
|
#include "e2fsck.h"
|
||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
|
|
||||||
|
extern e2fsck_t e2fsck_global_ctx; /* Try your very best not to use this! */
|
||||||
|
|
||||||
struct string {
|
struct string {
|
||||||
char *s;
|
char *s;
|
||||||
int len;
|
int len;
|
||||||
|
@ -233,6 +235,8 @@ static FILE *save_output(const char *s0, const char *s1, const char *s2)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pid == 0) {
|
if (pid == 0) {
|
||||||
|
if (e2fsck_global_ctx && e2fsck_global_ctx->progress_fd)
|
||||||
|
close(e2fsck_global_ctx->progress_fd);
|
||||||
if (daemon(0, 0) < 0) {
|
if (daemon(0, 0) < 0) {
|
||||||
perror("daemon");
|
perror("daemon");
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -112,7 +112,7 @@ need_block:
|
||||||
ext2fs_iblk_set(fs, &inode, 1);
|
ext2fs_iblk_set(fs, &inode, 1);
|
||||||
/* Slow symlinks, target stored in the first block */
|
/* Slow symlinks, target stored in the first block */
|
||||||
memset(block_buf, 0, fs->blocksize);
|
memset(block_buf, 0, fs->blocksize);
|
||||||
strcpy(block_buf, target);
|
strncpy(block_buf, target, fs->blocksize);
|
||||||
if (fs->super->s_feature_incompat &
|
if (fs->super->s_feature_incompat &
|
||||||
EXT3_FEATURE_INCOMPAT_EXTENTS) {
|
EXT3_FEATURE_INCOMPAT_EXTENTS) {
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -2311,8 +2311,10 @@ static errcode_t move_itables(ext2_resize_t rfs)
|
||||||
ext2fs_inode_table_loc(fs, i))
|
ext2fs_inode_table_loc(fs, i))
|
||||||
to_move++;
|
to_move++;
|
||||||
|
|
||||||
if (to_move == 0)
|
if (to_move == 0) {
|
||||||
return 0;
|
retval = 0;
|
||||||
|
goto errout;
|
||||||
|
}
|
||||||
|
|
||||||
if (rfs->progress) {
|
if (rfs->progress) {
|
||||||
retval = rfs->progress(rfs, E2_RSZ_MOVE_ITABLE_PASS,
|
retval = rfs->progress(rfs, E2_RSZ_MOVE_ITABLE_PASS,
|
||||||
|
|
Loading…
Reference in New Issue