Explorar o código

block: request_module(): use format string

Avoid bad things happening if the module has a printk control string in
its name.

Signed-off-by: maximilian attems <max@stro.at>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
maximilian attems %!s(int64=17) %!d(string=hai) anos
pai
achega
e180f59493
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      block/elevator.c

+ 1 - 1
block/elevator.c

@@ -150,7 +150,7 @@ static struct elevator_type *elevator_get(const char *name)
 		else
 			sprintf(elv, "%s-iosched", name);
 
-		request_module(elv);
+		request_module("%s", elv);
 		spin_lock(&elv_list_lock);
 		e = elevator_find(name);
 	}