master/module.c
changeset 1606 6c5849669900
parent 1586 eb9185dfa8ac
child 1814 23fcca9ef1fb
--- a/master/module.c	Fri Dec 18 11:09:07 2009 +0100
+++ b/master/module.c	Sun Dec 27 16:58:19 2009 +0100
@@ -471,7 +471,8 @@
             ec_device_attach(&master->main_device, net_dev, poll, module);
             up(&master->device_sem);
             
-            sprintf(net_dev->name, "ec%u", master->index);
+            snprintf(net_dev->name, IFNAMSIZ, "ec%u", master->index);
+
             return &master->main_device; // offer accepted
         }
         else {