Distributed Replicated Block Device (DRBD) development
 help / color / mirror / Atom feed
* [Drbd-dev] Potentially invalid memory accesses in file drivers/block/drbd/drbd_worker.c
@ 2017-07-20  4:50 Shaobo
  2017-07-20 12:10 ` Roland Kammerer
  0 siblings, 1 reply; 2+ messages in thread
From: Shaobo @ 2017-07-20  4:50 UTC (permalink / raw)
  To: drbd-dev; +Cc: lars.ellenberg, philipp.reisner

Hi there,

My name is Shaobo He and I am a graduate student at University of Utah. 
I am using a static analysis tool to search for null pointer 
dereferences and came across a couple of potentially invalid memory 
accesses in the file drivers/block/drbd/drbd_worker.c: in function 
`drbd_start_resync`, pointer variable `connection` in line 1727 can be 
NULL while is dereferenced at line 1767 (```if (current == 
connection->worker.task) {```).

Please let me know if it makes sense. I am looking forward to your 
reply.

Best,
Shaobo

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Drbd-dev] Potentially invalid memory accesses in file drivers/block/drbd/drbd_worker.c
  2017-07-20  4:50 [Drbd-dev] Potentially invalid memory accesses in file drivers/block/drbd/drbd_worker.c Shaobo
@ 2017-07-20 12:10 ` Roland Kammerer
  0 siblings, 0 replies; 2+ messages in thread
From: Roland Kammerer @ 2017-07-20 12:10 UTC (permalink / raw)
  To: drbd-dev

On Wed, Jul 19, 2017 at 10:50:47PM -0600, Shaobo wrote:
> Hi there,
> 
> My name is Shaobo He and I am a graduate student at University of Utah. I am
> using a static analysis tool to search for null pointer dereferences and
> came across a couple of potentially invalid memory accesses in the file
> drivers/block/drbd/drbd_worker.c: in function `drbd_start_resync`, pointer
> variable `connection` in line 1727 can be NULL while is dereferenced at line
> 1767 (```if (current == connection->worker.task) {```).
> 
> Please let me know if it makes sense. I am looking forward to your reply.

Hi Shaobo,

While highly theoretical and unlikely, better be safe than sorry. Fixed
and we will send that to mainline Linux soon.

Regards, rck

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-07-20 12:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-20  4:50 [Drbd-dev] Potentially invalid memory accesses in file drivers/block/drbd/drbd_worker.c Shaobo
2017-07-20 12:10 ` Roland Kammerer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox