How use Instruments and display the console in Command Lines applications
问题 I'm using Xcode on OSX to develop command line C applications. I would also like to use Instruments to profile and find memory leaks. However, I couldn't find a way to display the console when launching the application from within Instruments. I'm also unable to attach to a running command line process (it exits with an error): Here's an example code: #include <stdio.h> #include <signal.h> #include <stdlib.h> #include <setjmp.h> static sigjmp_buf jmpbuf; void handler(int sig) { char c[BUFSIZ]