Issue passing optional parameters into C execlp()

Solution 1:

By convention, the first parameter to a process (accessible as argv[0]) is the name of the process. You haven't included that, so "-resize 10%" is read as the process name instead of an option.

Also, "-resize 10%" is actually two parameters separated by a space, so you need to split them up.

rc = execlp("convert", "convert", "-resize", "10%", src, dst, NULL);