remove duplicated tx rollback
Signed-off-by: guodong <guodong9211@gmail.com>
This commit is contained in:
		| @@ -456,9 +456,6 @@ func (o *snapshotter) createSnapshot(ctx context.Context, kind snapshots.Kind, k | |||||||
| 		stat := st.Sys().(*syscall.Stat_t) | 		stat := st.Sys().(*syscall.Stat_t) | ||||||
|  |  | ||||||
| 		if err := os.Lchown(filepath.Join(td, "fs"), int(stat.Uid), int(stat.Gid)); err != nil { | 		if err := os.Lchown(filepath.Join(td, "fs"), int(stat.Uid), int(stat.Gid)); err != nil { | ||||||
| 			if rerr := t.Rollback(); rerr != nil { |  | ||||||
| 				log.G(ctx).WithError(rerr).Warn("failed to rollback transaction") |  | ||||||
| 			} |  | ||||||
| 			return nil, fmt.Errorf("failed to chown: %w", err) | 			return nil, fmt.Errorf("failed to chown: %w", err) | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 guodong
					guodong