What is this error - Symbols loaded

What is this error - Symbols loaded

Dear All,

Can somebody help me that what are these following errors. I am working with a C project
in visual studio 2008 and fortran compiler Version 11.1 . I made some property configurations and
ran the project. I have no clue on these errors!!!!!!!!

 

Visual Studio 2008\test_lib.exe', Symbols loaded.

The program '[2980] test_lib.exe: Native' has exited with code -1 (0xffffffff).

I hope, I posted the question in right forum section if not, kindly redirct or inform something favorable.

 

16 帖子 / 0 全新
最新文章
如需更全面地了解编译器优化,请参阅优化注意事项

move your C question to the C++ forum

In Visual Studio IDE, set break point at start of main (_main, WinMain, ...), then run. If this errors before you break then start debug session from IDE with "Step Into". This will (should) allow you to step through the C Run Time library initialization.

Jim Dempsey

www.quickthreadprogramming.com

Neither of those messages are errors. They are informational status messages from the debugger. The only one of real interest is the last one that says your main program completed and returned a status value of -1. That could be normal, especially if the main program was written in C, though 0 is the more common "success" exit status. We'd have to see your main program to comment further.

Steve

ANSI C only requires that EXIT_SUCCESS and EXIT_FAILURE be defined as possible exit codes, and these are usually 0 and 1. Often, the allowed values are 0-255, with the 128-255 range not recommended for user code.

It is a little unusual to see the value reported (-1). Could it have come from the C start-up code?

Dear Jimm; Steve; Mecej,

Thanks for all your good advice and response.

C project solution is running fine!!!!!!! I beleive so

I Missed to mention that I have 10 fortran files(f90) in fortran library solution with

my C project, this fortran solution tagged for testing the C project. I guess I am getting

this warning while running fortran solution so want to know, is there any configurational issues with

its property setting ????????

Kindly help

If the exit code of -1 is issued prior to your first statement in your C main(...
Then an error is occuring in the C Runtime Library initialization code.
If the issue is a missing DLL then a message should be output somewhere (console, dialog box, ...)
But it may not be....
Therefore, it may be necessary to use Debug | Step Into to step it the C Runtime Library initialization code (as opposed to auto break point at main as with Debug | Run).

VS comes with the sources to (most of) the C runtime library, you may need to specify the path to those sources when at first break.

Jim Dempsey

www.quickthreadprogramming.com

Dear Steve

As you suggested, I am putting my Main file code for getting your comment further. Two main files I am pasting 1) Main File for C projcet --->main.c
2)Main File for Fortran Project ---->main.f90. Please advice me quickly....

Note:
*****

I saw '-1' returen value in main.c file but I changed that value and executed( say -55) but still -1 returns
and debugger is not coming to this code line. I dont have much idea on fotran coding and its debugging, please advice.

Dear Jimm,

Thanks a lot for answer again. But I tried to debugg but debugger is not at all coming on to my code lines, then How can I do Step Into9(F11) options. Please advice

The lengthy Fortran listing that you provided is of limited usefulness since you have not described the connection between the C program and the Fortran program.

In particular, you did not show the code for the function called in the C program, namely, createTotalMg1g1(). If something went wrong while executing that function, it is possible that the return code would remain at the initial value assigned to it (-1).

Dear jimdem,

While I am debugging, I found the program is exiting on this particular line with '-1'

crt0.c
--------

if ( !managedapp )
exit(mainret);

_cexit();

Line no: 269

and in "Go to definition" option diaplays ... The symbol 'managedapp' is not defind.

can you consult me now what is this issue.

Ajain,

The C code you show is part of the Microsoft C run-time library and not your program. By the time that code is reached it is already past the cause of the return status. You have to show us your actual C code (attach it as a file rather than pasting it into the reply.)

Steve

Dear Steve,

Thanks for replaying me quickly, I understand that it is not part of my code and it is one
library file but why the debugger is not coming to my main.c file so I debugged this way

solution right click --> Debugg ---> step into new instance

This time I have attached my build html repot, please verify and help me...

Note:

1)I have two projects. C (mg1g1) and fortran 90 (test_lib). Fortran solution is for making perfomance testing environment for C project.

2) project directory Bin contains only .exe file for test_lib, doesnt have .exe for C project ... is it a reason??????

附件: 

附件尺寸
下载 build-log.docx129.7 KB

You sent me in a private message the C main, which is quite simple. It does show that the main program could exit with a status of -1, but you'd have to step through it in the debugger to see why. You can set a breakpoint on any line of code by clicking in the left column of the line. You should then use Step Into to step into routines and trace the program flow.

Steve

Okay Steve, I put break ponit in both main.c & main.f90 but debugging is not happening. It gives only vss output messages(for build). This project is console application so I hope some different debugg configuration setting should be set, I am trying in that way. Thanks for your good advice!!!!!!!!!

You have to start the program with the debugger (press F5).

Steve

All right I am doing the same!!!!!!!!!! Thanks a lot Steve.

登陆并发表评论。