function::set_longlong_arg - Linux


The set_longlong_arg function is used to set the value of a signed 64-bit integer argument.


void set_longlong_arg(int index, long long value);

The following parameters are accepted:

  • index: The index of the argument to set.
  • value: The value to set the argument to.


This function does not take any options or flags.


The following code sets the value of the first argument to 1234567890123456789:

set_longlong_arg(0, 1234567890123456789);

Common Issues

One common issue that can occur is that the argument index is out of range. This will cause the function to fail and an error message to be printed.


This function can be used with other Linux commands and tools to set the value of arguments for other programs. For example, the following command sets the --value argument of the my_program program to 1234567890123456789:

my_program --value=$(set_longlong_arg 0 1234567890123456789)

Related Commands

  • get_longlong_arg: Gets the value of a signed 64-bit integer argument.
  • set_int_arg: Sets the value of a signed 32-bit integer argument.