Skip to content

mxqsub: Implement --tmpdir argument without units #158

Merged
merged 1 commit into from
May 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 4 additions & 1 deletion mxqsub.c
Original file line number Diff line number Diff line change
Expand Up @@ -989,7 +989,10 @@ int main(int argc, char *argv[])
break;

case 7:
{
u_int64_t arg_tmpdir_mb;
if (mx_strtou64(optctl.optarg, &arg_tmpdir_mb) == 0) {
arg_tmpdir = (arg_tmpdir_mb+1024-1)/1024;
} else {
unsigned long long int bytes;
if(mx_strtobytes(optctl.optarg, &bytes) < 0) {
mx_log_crit("--tmpdir '%s': %m", optctl.optarg);
Expand Down