diff --git a/sched/adjust_user_priority.cpp b/sched/adjust_user_priority.cpp index bf99fdbd18..9ae3fe0129 100644 --- a/sched/adjust_user_priority.cpp +++ b/sched/adjust_user_priority.cpp @@ -80,7 +80,7 @@ int main(int argc, char** argv) { } DB_APP app; - sprintf(buf, "where name='%s'", app_name); + snprintf(buf, sizeof(buf), "where name='%s'", app_name); retval = app.lookup(buf); if (retval) { fprintf(stderr, "no such app %s\n", argv[3]);