Bug in drbd_adm_attach()
Hello,
Coverity has spotted a problem in drbd_adm_attach() which does:
connection = peer_device ? peer_device->connection : NULL;
conn_reconfig_start(connection);and conn_reconfig_start() just blindly dereferences 'connection'. So either peer_device cannot be NULL (and then the test is superfluous) or there's a bug...
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Philipp Reisner
maintainerAm Dienstag, 21. Oktober 2014, 16:12:26 schrieb Jan Kara:
Quoted 4 lines
Hello,
Coverity has spotted a problem in
drbd_adm_attach()which does:
Quoted 8 lines
connection = peer_device ? peer_device->connection : NULL; conn_reconfig_start(connection);and
conn_reconfig_start()just blindly dereferences 'connection'. So eitherpeer_devicecannot be NULL (and then the test is superfluous) or there's a bug...Honza
Thanks for pointing out.
http://git.drbd.org/gitweb.cgi?p=drbd-8.4.git;a=commitdiff;h=8d7d18b40dbe006a3ca25d560e42617a04c68e1f;hp=1564eb39534debeead593f597c5c951c588ecf8b
Best,
Phil