1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

libdm: replace assign with increment

Coverity didn't liked assign with && expression, so use trick.
It does not complain against this prefix incremenent operation.
This commit is contained in:
Zdenek Kabelac 2015-11-09 22:48:13 +01:00
parent 7ec61cd5b9
commit fb59847a0f

View File

@ -1,6 +1,6 @@
/* /*
* Copyright (C) 2002-2004 Sistina Software, Inc. All rights reserved. * Copyright (C) 2002-2004 Sistina Software, Inc. All rights reserved.
* Copyright (C) 2004-2007 Red Hat, Inc. All rights reserved. * Copyright (C) 2004-2015 Red Hat, Inc. All rights reserved.
* *
* This file is part of the device-mapper userspace tools. * This file is part of the device-mapper userspace tools.
* *
@ -2219,8 +2219,7 @@ static const char *_tok_value_number(const char *s,
int is_float = 0; int is_float = 0;
*begin = s; *begin = s;
/* coverity[assign_where_compare_meant] */ while ((!is_float && (*s == '.') && ++is_float) || isdigit(*s))
while ((!is_float && (*s == '.') && ((is_float = 1))) || isdigit(*s))
s++; s++;
*end = s; *end = s;