diff options
Diffstat (limited to 'drivers/input/joystick/cobra.c')
-rw-r--r-- | drivers/input/joystick/cobra.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/input/joystick/cobra.c b/drivers/input/joystick/cobra.c index 1909f7ef340c..d5e42eb88a20 100644 --- a/drivers/input/joystick/cobra.c +++ b/drivers/input/joystick/cobra.c | |||
@@ -202,7 +202,8 @@ static int cobra_connect(struct gameport *gameport, struct gameport_driver *drv) | |||
202 | goto fail3; | 202 | goto fail3; |
203 | } | 203 | } |
204 | 204 | ||
205 | sprintf(cobra->phys[i], "%s/input%d", gameport->phys, i); | 205 | snprintf(cobra->phys[i], sizeof(cobra->phys[i]), |
206 | "%s/input%d", gameport->phys, i); | ||
206 | 207 | ||
207 | input_dev->name = "Creative Labs Blaster GamePad Cobra"; | 208 | input_dev->name = "Creative Labs Blaster GamePad Cobra"; |
208 | input_dev->phys = cobra->phys[i]; | 209 | input_dev->phys = cobra->phys[i]; |