#! /bin/sh /usr/share/dpatch/dpatch-run ## 02_fix_long_options.dpatch by Cesare Tirabassi ## ## All lines beginning with `## DP:' are a description of the patch. ## DP: Fix long options list of arguments. @DPATCH@ diff -urNad cpulimit-1.1~/cpulimit.c cpulimit-1.1/cpulimit.c --- cpulimit-1.1~/cpulimit.c 2005-06-27 02:15:23.000000000 +0200 +++ cpulimit-1.1/cpulimit.c 2008-06-20 15:13:19.000000000 +0200 @@ -357,13 +357,13 @@ const char* short_options="p:e:P:l:vzh"; /* An array describing valid long options. */ const struct option long_options[] = { - { "pid", 0, NULL, 'p' }, - { "exe", 1, NULL, 'e' }, - { "path", 0, NULL, 'P' }, - { "limit", 0, NULL, 'l' }, - { "verbose", 0, NULL, 'v' }, - { "lazy", 0, NULL, 'z' }, - { "help", 0, NULL, 'h' }, + { "pid", required_argument, NULL, 'p' }, + { "exe", required_argument, NULL, 'e' }, + { "path", required_argument, NULL, 'P' }, + { "limit", required_argument, NULL, 'l' }, + { "verbose", no_argument, NULL, 'v' }, + { "lazy", no_argument, NULL, 'z' }, + { "help", no_argument, NULL, 'h' }, { NULL, 0, NULL, 0 } }; //argument variables