I have a crash (program unexpectly exited) in my code. Trying to debug it with printf, I come to the line:
int tiempo_seguridad[12] = { 0, 25, 100, 100, 200, 200, 200, 300, 300, 300,...
Type: Posts; User: Kempelen
I have a crash (program unexpectly exited) in my code. Trying to debug it with printf, I come to the line:
int tiempo_seguridad[12] = { 0, 25, 100, 100, 200, 200, 200, 300, 300, 300,...
Look at this code
my_tmp_function() {
int array1[4096]
long array2[other big size]
... a few more big arrays...
}
I have a similar code in my program. At runtime, memory is a...
Hello,
I have a complex program, around 25.000 code lines. It is quite stable, but I have a bug which only happens from time to time, and when in online-mode, so it is quite difficult for me to...
Hello,
After I upgraded my development machine and test machine to windows 7 and 8, my programs open a window (cancel, retry or ignore) when a file or disk is not found:
FILE *fOut =...
Hello,
I think I have detected where the problem is and ........ is it not in my code, but the way my application work. I explain looking for help: I have four .bat files (in windows 7) that copy...
int main(int argc, char *argv[]) {
/* ---- Ponemos la consola en modo unbuffered ---- */
setbuf(stdout, NULL);
setbuf(stdin, NULL);
setvbuf(stdout, NULL, _IONBF,...
I am trying to catch signals with:
signal(SIGINT, SIG_IGN);
signal(SIGABRT, GestionSenales);
signal(SIGFPE, GestionSenales);
signal(SIGILL, GestionSenales);
...
Hello,
I have a problem with a C program I have developed and I need same advice. First I describe the environment: program has around 700 lines of code, windows 7, MINGW. I have a "clean"...
I have a program that printf a float that is returned by a function like this:
printf("%3.1f\n", myfloat());
...
float myfloat(void) {
code....
}
Thanks, it works perfect.
I need help because what I want, I dont know if it is possible to do it with macros.
I have:
#ifdef ESTADISTICAS
# define S(x) (x)
#else
# define S(x)
#endif
It is called only one time and free at the end of the program. No loop.
The only datail that maybe is of importance is that I malloc a big chunk of memory (128 MB). I could do it without malloc,...
Hello,
I have a program which call only one time malloc at the start of the program. When running, I see with 'process-explorer.exe' that memory is growing in little steps. Is this normal? why?
...
Thanks. I was thinking more in a way to do a complete report. Of course I could go function by function to check with that tricks, but that would be endless.
If this is my code, you ask why?....
Hello,
I would like to know if is there a tool, script, source code or similar (one or more) that can tell me:
* if a function is not used outside is file, so I can declare it static...
Hello,
I have developed a program which has a function name 'cargarDLL' that inside it load a DLL made by an external developer (I mean, I have no control over dll source code).
My...
Hi,
GCC has a nice feature about instrumentation which let you call a routine every time a function is called, or every time a function returns.
Now, I want to create my own system to make it...
Thanks, today I have learn something I didn't know before. To make a shift (not for dividing) you must know the sign influence the result, so that if you expect a diferent result other operations...
Thanks, this goes in the direction in the answer I hoped. Anyway if I use a shift in my code (not for the porposes of dividing), and I want always to be filled with 0, or 1 at right, how I do that?
Of course the result would be the same, but I am not asking if the shight will produce the same result, what I am asking is if the compile can replace the division by a shift, and It cann't because...
What I want is to know how the compiler works because knowledge is better for any programmer. It could be worthy for your propouses or be only general culture. Both are positive.
You say is...
A question about performance:
int x = 0;
...
...
x = 123456 * z; // z is not zero, is dynamic
int y = x / 2;
Everywhere I read this is a shift operation, but this to me seem like the...
Not. I have tested it outside IDE and the problems continues.
My program open and used data files at opening that seem to be cached. That is the problem. I would like to improve this start up...
Hello,
I have a run-time problem with my application. When I first turn on my PC, compile my application and execute it, it takes around 20 to 30 to "get ready". It is the process of start-up what...
thanks again for the unswer. I knows the difference between compiled and interpreted. Maybe I express myself bad. What I didnt know is how S.O. load the executable into memory. In fact, I dont know...