chiark / gitweb /
sd-rtnl: don't assign to unused variable
authorTom Gundersen <teg@jklm.no>
Mon, 1 Sep 2014 20:59:52 +0000 (22:59 +0200)
committerTom Gundersen <teg@jklm.no>
Mon, 1 Sep 2014 20:59:52 +0000 (22:59 +0200)
Reported by Thomas H.P. Andersen <phomes@gmail.com>.

src/libsystemd/sd-rtnl/rtnl-message.c

index 906a9de1c098a7261f41e9fbbf5a05391720c532..30e33584c4ac649cac0a833707b62dad00d6825e 100644 (file)
@@ -531,7 +531,6 @@ static int add_rtattr(sd_rtnl_message *m, unsigned short type, const void *data,
                 /* if no data was passed, make sure we still initialize the padding
                    note that we can have data_length > 0 (used by some containers) */
                 padding = RTA_DATA(rta);
-                data_length = 0;
         }
 
         /* make sure also the padding at the end of the message is initialized */