* [PATCH 1/3] e2image: Remove useless exit call
@ 2013-03-16 9:13 Tomas Racek
2013-03-16 9:13 ` [PATCH 2/3] e2image: man: fix typo Tomas Racek
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Tomas Racek @ 2013-03-16 9:13 UTC (permalink / raw)
To: linux-ext4; +Cc: Tomas Racek
Exit is called right after the install_image anyway so this one can
be removed.
Signed-off-by: Tomas Racek <tracek@redhat.com>
---
misc/e2image.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/misc/e2image.c b/misc/e2image.c
index b1badda..6988c4d 100644
--- a/misc/e2image.c
+++ b/misc/e2image.c
@@ -1230,7 +1230,6 @@ static void install_image(char *device, char *image_fn, int type)
}
ext2fs_close (fs);
- exit (0);
}
static struct ext2_qcow2_hdr *check_qcow2_image(int *fd, char *name)
--
1.7.11.7
^ permalink raw reply related [flat|nested] 7+ messages in thread* [PATCH 2/3] e2image: man: fix typo
2013-03-16 9:13 [PATCH 1/3] e2image: Remove useless exit call Tomas Racek
@ 2013-03-16 9:13 ` Tomas Racek
2013-04-22 3:23 ` Theodore Ts'o
2013-03-16 9:13 ` [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image Tomas Racek
2013-04-22 3:23 ` [PATCH 1/3] e2image: Remove useless exit call Theodore Ts'o
2 siblings, 1 reply; 7+ messages in thread
From: Tomas Racek @ 2013-03-16 9:13 UTC (permalink / raw)
To: linux-ext4; +Cc: Tomas Racek
Signed-off-by: Tomas Racek <tracek@redhat.com>
---
misc/e2image.8.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/misc/e2image.8.in b/misc/e2image.8.in
index 0972826..84b9729 100644
--- a/misc/e2image.8.in
+++ b/misc/e2image.8.in
@@ -187,7 +187,7 @@ Normally
only includes fs metadata, not regular file data. The
.B \-a
option can be specified to include all data. This will
-give an image that is suitible to use to clone the entire FS or
+give an image that is suitable to use to clone the entire FS or
for backup purposes. Note that this option only works with the
raw or QCOW2 formats.
.PP
--
1.7.11.7
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image
2013-03-16 9:13 [PATCH 1/3] e2image: Remove useless exit call Tomas Racek
2013-03-16 9:13 ` [PATCH 2/3] e2image: man: fix typo Tomas Racek
@ 2013-03-16 9:13 ` Tomas Racek
2013-03-18 15:42 ` Eric Sandeen
2013-04-22 3:23 ` Theodore Ts'o
2013-04-22 3:23 ` [PATCH 1/3] e2image: Remove useless exit call Theodore Ts'o
2 siblings, 2 replies; 7+ messages in thread
From: Tomas Racek @ 2013-03-16 9:13 UTC (permalink / raw)
To: linux-ext4; +Cc: Tomas Racek
All data cannot be included in normal image file so e2image should exit
in this case.
Signed-off-by: Tomas Racek <tracek@redhat.com>
---
misc/e2image.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/misc/e2image.c b/misc/e2image.c
index 6988c4d..b4e4cf9 100644
--- a/misc/e2image.c
+++ b/misc/e2image.c
@@ -1295,6 +1295,13 @@ int main (int argc, char ** argv)
}
if (optind != argc - 2 )
usage();
+
+ if(all_data && !img_type) {
+ com_err(program_name, 0, "-a option can only be used "
+ "with raw or QCOW2 images.");
+ exit(1);
+ }
+
device_name = argv[optind];
image_fn = argv[optind+1];
--
1.7.11.7
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image
2013-03-16 9:13 ` [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image Tomas Racek
@ 2013-03-18 15:42 ` Eric Sandeen
2013-04-22 3:23 ` Theodore Ts'o
1 sibling, 0 replies; 7+ messages in thread
From: Eric Sandeen @ 2013-03-18 15:42 UTC (permalink / raw)
To: Tomas Racek; +Cc: linux-ext4
On 3/16/13 4:13 AM, Tomas Racek wrote:
> All data cannot be included in normal image file so e2image should exit
> in this case.
>
> Signed-off-by: Tomas Racek <tracek@redhat.com>
> ---
> misc/e2image.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/misc/e2image.c b/misc/e2image.c
> index 6988c4d..b4e4cf9 100644
> --- a/misc/e2image.c
> +++ b/misc/e2image.c
> @@ -1295,6 +1295,13 @@ int main (int argc, char ** argv)
> }
> if (optind != argc - 2 )
> usage();
> +
> + if(all_data && !img_type) {
^
nitpick, add space. Can probably be fixed on merge, otherwise:
Also - what is the result today if -a is specified w/o -r or -Q?
The change itself looks good, though, so:
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
> + com_err(program_name, 0, "-a option can only be used "
> + "with raw or QCOW2 images.");
> + exit(1);
> + }
> +
> device_name = argv[optind];
> image_fn = argv[optind+1];
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image
2013-03-16 9:13 ` [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image Tomas Racek
2013-03-18 15:42 ` Eric Sandeen
@ 2013-04-22 3:23 ` Theodore Ts'o
1 sibling, 0 replies; 7+ messages in thread
From: Theodore Ts'o @ 2013-04-22 3:23 UTC (permalink / raw)
To: Tomas Racek; +Cc: linux-ext4
On Sat, Mar 16, 2013 at 10:13:25AM +0100, Tomas Racek wrote:
> All data cannot be included in normal image file so e2image should exit
> in this case.
>
> Signed-off-by: Tomas Racek <tracek@redhat.com>
Thanks, applied with the whitespace nit which Eric pointed out fixed.
- Ted
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/3] e2image: Remove useless exit call
2013-03-16 9:13 [PATCH 1/3] e2image: Remove useless exit call Tomas Racek
2013-03-16 9:13 ` [PATCH 2/3] e2image: man: fix typo Tomas Racek
2013-03-16 9:13 ` [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image Tomas Racek
@ 2013-04-22 3:23 ` Theodore Ts'o
2 siblings, 0 replies; 7+ messages in thread
From: Theodore Ts'o @ 2013-04-22 3:23 UTC (permalink / raw)
To: Tomas Racek; +Cc: linux-ext4
On Sat, Mar 16, 2013 at 10:13:23AM +0100, Tomas Racek wrote:
> Exit is called right after the install_image anyway so this one can
> be removed.
>
> Signed-off-by: Tomas Racek <tracek@redhat.com>
Thanks, applied.
- Ted
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2013-04-22 3:23 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-16 9:13 [PATCH 1/3] e2image: Remove useless exit call Tomas Racek
2013-03-16 9:13 ` [PATCH 2/3] e2image: man: fix typo Tomas Racek
2013-04-22 3:23 ` Theodore Ts'o
2013-03-16 9:13 ` [PATCH 3/3] e2image: require that -a option is used only with raw or QCOW2 image Tomas Racek
2013-03-18 15:42 ` Eric Sandeen
2013-04-22 3:23 ` Theodore Ts'o
2013-04-22 3:23 ` [PATCH 1/3] e2image: Remove useless exit call Theodore Ts'o
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.