Patchwork [09/25] uuidd: Add missing break to option case statement

login
register
mail settings
Submitter Eric Sandeen
Date Sept. 16, 2011, 8:49 p.m.
Message ID <1316206180-6375-10-git-send-email-sandeen@redhat.com>
Download mbox | patch
Permalink /patch/115051/
State Accepted
Headers show

Comments

Eric Sandeen - Sept. 16, 2011, 8:49 p.m.
Specifying the "-n" option to uuidd would incorrectly
fall through to the "-p" case, and assign that number to
the pidfile_path.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
 misc/uuidd.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Theodore Ts'o - Sept. 16, 2011, 10:54 p.m.
On Fri, Sep 16, 2011 at 03:49:24PM -0500, Eric Sandeen wrote:
> Specifying the "-n" option to uuidd would incorrectly
> fall through to the "-p" case, and assign that number to
> the pidfile_path.
> 
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>

Applied, thanks.

Can you do me a favor and make sure this gets fixed in util-linux-ng
as well?

	 			- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Eric Sandeen - Sept. 17, 2011, 12:47 a.m.
On 9/16/11 5:54 PM, Ted Ts'o wrote:
> On Fri, Sep 16, 2011 at 03:49:24PM -0500, Eric Sandeen wrote:
>> Specifying the "-n" option to uuidd would incorrectly
>> fall through to the "-p" case, and assign that number to
>> the pidfile_path.
>>
>> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> 
> Applied, thanks.
> 
> Can you do me a favor and make sure this gets fixed in util-linux-ng
> as well?

sure thing

-eric

> 	 			- Ted
> --
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/misc/uuidd.c b/misc/uuidd.c
index 89bff72..912773a 100644
--- a/misc/uuidd.c
+++ b/misc/uuidd.c
@@ -472,6 +472,7 @@  int main(int argc, char **argv)
 				fprintf(stderr, _("Bad number: %s\n"), optarg);
 				exit(1);
 			}
+			break;
 		case 'p':
 			pidfile_path = optarg;
 			drop_privs = 1;