[DVDnav-discuss] vm.c - remove extra parenthesis

Steve Dibb git at videolan.org
Wed Apr 16 13:07:43 CEST 2014


libdvdnav | branch: master | Steve Dibb <beandog at gentoo.org> | Tue Apr 15 13:31:38 2014 -0600| [d58950ef901a23b9b25ab9d5e4988b451c768e55] | committer: Jean-Baptiste Kempf

vm.c - remove extra parenthesis

Fixes compiler warning:

src/vm/vm.c:183:17: warning: equality comparison with extraneous
parentheses [-Wparentheses-equality]
    if((data[i] == 0)) break;
        ~~~~~~~~^~~~

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/libdvdnav.git/?a=commit;h=d58950ef901a23b9b25ab9d5e4988b451c768e55
---

 src/vm/vm.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/vm/vm.c b/src/vm/vm.c
index 0de93e3..14497f5 100644
--- a/src/vm/vm.c
+++ b/src/vm/vm.c
@@ -180,7 +180,7 @@ static int dvd_read_name(char *name, char *serial, const char *device) {
 
   fprintf(MSG_OUT, "libdvdnav: DVD Title: ");
   for(i=25; i < 73; i++ ) {
-    if((data[i] == 0)) break;
+    if(data[i] == 0) break;
     if((data[i] > 32) && (data[i] < 127)) {
       fprintf(MSG_OUT, "%c", data[i]);
     } else {
@@ -191,7 +191,7 @@ static int dvd_read_name(char *name, char *serial, const char *device) {
   name[48] = 0;
   fprintf(MSG_OUT, "\nlibdvdnav: DVD Serial Number: ");
   for(i=73; i < 89; i++ ) {
-    if((data[i] == 0)) break;
+    if(data[i] == 0) break;
     if((data[i] > 32) && (data[i] < 127)) {
       fprintf(MSG_OUT, "%c", data[i]);
     } else {
@@ -202,7 +202,7 @@ static int dvd_read_name(char *name, char *serial, const char *device) {
   serial[14] = 0;
   fprintf(MSG_OUT, "\nlibdvdnav: DVD Title (Alternative): ");
   for(i=89; i < 128; i++ ) {
-    if((data[i] == 0)) break;
+    if(data[i] == 0) break;
     if((data[i] > 32) && (data[i] < 127)) {
       fprintf(MSG_OUT, "%c", data[i]);
     } else {



More information about the DVDnav-discuss mailing list