53a54
> #include <paths.h>
105c106
< if (!strncmp(argv[2], "/dev/", 5))
---
> if (!strncmp(argv[2], _PATH_DEV, strlen(_PATH_DEV)))
235c236
< (void)sprintf(path, "/dev/%s", tty);
---
> (void)snprintf(path, sizeof(path), "%s%s", _PATH_DEV, tty);
267c268
< (void)sprintf(path, "/dev/%s", tty);
---
> (void)snprintf(path, sizeof(path), "%s%s", _PATH_DEV, tty);
> #include <paths.h>
105c106
< if (!strncmp(argv[2], "/dev/", 5))
---
> if (!strncmp(argv[2], _PATH_DEV, strlen(_PATH_DEV)))
235c236
< (void)sprintf(path, "/dev/%s", tty);
---
> (void)snprintf(path, sizeof(path), "%s%s", _PATH_DEV, tty);
267c268
< (void)sprintf(path, "/dev/%s", tty);
---
> (void)snprintf(path, sizeof(path), "%s%s", _PATH_DEV, tty);