ltratt / multitime

Time command execution over multiple executions
http://tratt.net/laurie/src/multitime/
MIT License
115 stars 13 forks source link

Segmentation fault on OSX when running without '-f liketime' #22

Closed zbentley closed 6 years ago

zbentley commented 6 years ago

Environment

OSX 10.13.4.

Apple LLVM version 9.1.0 (clang-902.0.39.1) Target: x86_64-apple-darwin17.5.0 Thread model: posix

autoconf (GNU Autoconf) 2.69

Observed behavior

On OSX, any output format option other than liketime segfaults after running the command the specified number of times.

#> multitime -f rusage -n 2 sleep 1
===> multitime results
Segmentation fault: 11
#> multitime -n 2 sleep 1
===> multitime results
Segmentation fault: 11

liketime works fine though:

#> multitime -f liketime -n 2 sleep 1
real         1.00
user         0.00
sys          0.00

Expected behavior

No segfaults.

ltratt commented 6 years ago

Unfortunately I don't have an OS X machine to try this on, so to have any chance of fixing this, I'm going to need help. Can you run gdb to find out where it's segfaulting, for example?

zbentley commented 6 years ago

I'll do that, but it's my first time using the GDB toolset for debugging, so I apologize if it takes me a bit to learn and I don't get back to you for a few days ($day_job and all that). I'll be sure to follow up, though. Thanks for responding!