473,466 Members | 1,332 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Why are the mangled names are a bit different?

Hi, can anybody help please!

I've got an app with a few dlls. When I run the app I get the following
message in a message box:

The procedure entry point
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@VCAccessGroup@PAC500DB@@$00$0 A@UUI_24@Bus2Types@@$OBPE@K@2@XZ
could not be located in the dynamic link library.

Looking at the library with dependancy walker I find the exported symbol is:
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@UCAccessGroup@PAC500DB@@$02$0 0$0A@UUI_24@Bus2Types@@$0BPE@K@2@XZ

The main difference I see here is that CAddessGroup is preceeded with a V in
the error message, but the symbol really has a U infront of it. I found a
posting that mentions U preceeds struct names. That seems to make sense.

But why do I get a V in the error message, what does V mean and why would I
be getting a difference between what my app in importing compared to what the
dll exports?

Any help would be really appreciated.
Thanks,
-Scott
Nov 17 '05 #1
3 1343
Scott Langham wrote:
Hi, can anybody help please!

I've got an app with a few dlls. When I run the app I get the
following
message in a message box:
undname.exe, which is included with VC++ is your friend in cases like this.
Try it out (in your <vs-dir>/VC7/BIN directory).

The procedure entry point
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@VCAccessGroup@PAC500DB@@$00$0 A@UUI_24@Bus2Types@@$OBPE@K@2@XZ
could not be located in the dynamic link library.
Are you sure you pasted that name correctly? According to undname it's not
a valid decorated name.

Looking at the library with dependancy walker I find the exported
symbol is:
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@UCAccessGroup@PAC500DB@@$02$0 0$0A@UUI_24@Bus2Types@@$0BPE@K@2@XZ
This decodes to

public: static class PAC500DB::CEntityCollectionMap<
struct PAC500DB::CAccessGroup,3,1,0,struct Bus2Types::UI_24,500,unsigned
long> &
__cdecl PAC500DB::CThe500Database::GetAccessGroups(void)


The main difference I see here is that CAddessGroup is preceeded with
a V in
the error message, but the symbol really has a U infront of it. I
found a
posting that mentions U preceeds struct names. That seems to make
sense.

But why do I get a V in the error message, what does V mean and why
would I
be getting a difference between what my app in importing compared to
what the
dll exports?


A couple of suggestions:

1, Make sure that the DLL and the caller (another DLL or EXE) are compiled
with the same version of the compiler. The fact that the first name above
doesn't decode as a valid name under VC++ 7.1 while the second does suggests
to me that there might be two different compiler versions.

2. Make sure that all #defines (and command-line/IDE defined preprocessor
symbols) are the same when the header file that contains the definition for
PAC500DB::CThe500Database is seen in both modules (the DLL and the caller).

-cd

Nov 17 '05 #2
Hi Carl,

Thanks for the help. "undname.exe" is an excellent tool. You're right, I
couldn't copy the decorated name out of the message box, so I typed it in. I
put a O where there should have been a 0! The corrected version decoded to
something similar to the exported symbol... except instead of "struct
CAccessGroup" I got "class CAccessGroup".

This confused me for a bit longer because CAccessGroup is defined using
struct. However, it does derive from a class... it appears that this is
somehow affecting the decorated name, but it's different between the
__declspec(dllexport) and __declspec(dllimport) versions.

Anyway, I've changed CAccessGroup so that it's declared as a class instead
of a struct, and this seems to work ok.

The dll and exe are compiled in the same solution using Microsoft Visual C++
..NET 69586-335-0000007-18635.

-Thank-you very much for your speedy help,
Scott

"Carl Daniel [VC++ MVP]" wrote:
Scott Langham wrote:
Hi, can anybody help please!

I've got an app with a few dlls. When I run the app I get the
following
message in a message box:


undname.exe, which is included with VC++ is your friend in cases like this.
Try it out (in your <vs-dir>/VC7/BIN directory).

The procedure entry point
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@VCAccessGroup@PAC500DB@@$00$0 A@UUI_24@Bus2Types@@$OBPE@K@2@XZ
could not be located in the dynamic link library.


Are you sure you pasted that name correctly? According to undname it's not
a valid decorated name.

Looking at the library with dependancy walker I find the exported
symbol is:
?GetAccessGroups@CThe500Database@PAC500DB@@SAAAV?$ CEntityCollectionMap@UCAccessGroup@PAC500DB@@$02$0 0$0A@UUI_24@Bus2Types@@$0BPE@K@2@XZ


This decodes to

public: static class PAC500DB::CEntityCollectionMap<
struct PAC500DB::CAccessGroup,3,1,0,struct Bus2Types::UI_24,500,unsigned
long> &
__cdecl PAC500DB::CThe500Database::GetAccessGroups(void)


The main difference I see here is that CAddessGroup is preceeded with
a V in
the error message, but the symbol really has a U infront of it. I
found a
posting that mentions U preceeds struct names. That seems to make
sense.

But why do I get a V in the error message, what does V mean and why
would I
be getting a difference between what my app in importing compared to
what the
dll exports?


A couple of suggestions:

1, Make sure that the DLL and the caller (another DLL or EXE) are compiled
with the same version of the compiler. The fact that the first name above
doesn't decode as a valid name under VC++ 7.1 while the second does suggests
to me that there might be two different compiler versions.

2. Make sure that all #defines (and command-line/IDE defined preprocessor
symbols) are the same when the header file that contains the definition for
PAC500DB::CThe500Database is seen in both modules (the DLL and the caller).

-cd

Nov 17 '05 #3
Scott Langham wrote:
Hi Carl,

Thanks for the help. "undname.exe" is an excellent tool. You're right, I
couldn't copy the decorated name out of the message box, so I typed it in. I
put a O where there should have been a 0! The corrected version decoded to
something similar to the exported symbol... except instead of "struct
CAccessGroup" I got "class CAccessGroup".

This confused me for a bit longer because CAccessGroup is defined using
struct. However, it does derive from a class... it appears that this is
somehow affecting the decorated name, but it's different between the
__declspec(dllexport) and __declspec(dllimport) versions.

Anyway, I've changed CAccessGroup so that it's declared as a class instead
of a struct, and this seems to work ok.

The dll and exe are compiled in the same solution using Microsoft Visual C++
..NET 69586-335-0000007-18635.

-Thank-you very much for your speedy help,
Scott

"Carl Daniel [VC++ MVP]" wrote:

Scott Langham wrote:
Hi, can anybody help please!

I've got an app with a few dlls. When I run the app I get the
following
message in a message box:


undname.exe, which is included with VC++ is your friend in cases like this.
Try it out (in your <vs-dir>/VC7/BIN directory).

The procedure entry point
?GetAccessGroups@CThe500Database@PAC500DB@@SAAA V?$CEntityCollectionMap@VCAccessGroup@PAC500DB@@$0 0$0A@UUI_24@Bus2Types@@$OBPE@K@2@XZ
could not be located in the dynamic link library.


Are you sure you pasted that name correctly? According to undname it's not
a valid decorated name.

Looking at the library with dependancy walker I find the exported
symbol is:
?GetAccessGroups@CThe500Database@PAC500DB@@SAAA V?$CEntityCollectionMap@UCAccessGroup@PAC500DB@@$0 2$00$0A@UUI_24@Bus2Types@@$0BPE@K@2@XZ


This decodes to

public: static class PAC500DB::CEntityCollectionMap<
struct PAC500DB::CAccessGroup,3,1,0,struct Bus2Types::UI_24,500,unsigned
long> &
__cdecl PAC500DB::CThe500Database::GetAccessGroups(void)
The main difference I see here is that CAddessGroup is preceeded with
a V in
the error message, but the symbol really has a U infront of it. I
found a
posting that mentions U preceeds struct names. That seems to make
sense.

But why do I get a V in the error message, what does V mean and why
would I
be getting a difference between what my app in importing compared to
what the
dll exports?


A couple of suggestions:

1, Make sure that the DLL and the caller (another DLL or EXE) are compiled
with the same version of the compiler. The fact that the first name above
doesn't decode as a valid name under VC++ 7.1 while the second does suggests
to me that there might be two different compiler versions.

2. Make sure that all #defines (and command-line/IDE defined preprocessor
symbols) are the same when the header file that contains the definition for
PAC500DB::CThe500Database is seen in both modules (the DLL and the caller).

-cd


Yes that is an unfortunate bug in our compiler. We should not name
decorate a class and a struct differently, but fixing this would
completely break binary compatibility so it is something we cannot do.
Of course the fix in the source is as you already did.

Ronald Laeremans
Visual C++ team
Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

22
by: BRIAN VICKERY | last post by:
I've heard that some compilers reserve the '_' starting a symbol for system variables/symbols. I can not find this documented anywhere (so far). I've used an '_' at the end of member variables...
1
by: Glenn Davy | last post by:
Hi Can any one tell me what is meant if access appends a ";1" to the names of stored procedures? Note, that the ";1" isn't already part of the name of the procedures name as they exist in the...
7
by: Ido Yehieli | last post by:
Hi, I was trying to download and install the latest SLUT (0.9.0) from http://slut.sourceforge.net/download/index.html and it seems both the zip and the tar.gz files are corrupted - the directory...
0
by: seek help | last post by:
Hello, IDE: VS .NET 2003. Problem: Mangled bits of gc class embedded within native C++ class. Description: I have a gc class, BoxedInfo. This wraps a Value type structure, NotiInfo....
6
by: Gerard Flanagan | last post by:
Hello all I would like to do the following: from elementtree.SimpleXMLWriter import XMLWriter class HtmlWriter(XMLWriter, object): def write_raw(self, text): super( HtmlWriter, self...
7
by: jccorreu | last post by:
I've got to read info from multiple files that will be given to me. I know the format and what the data is. The thing is each time we run the program we may be using a differnt number of files,...
2
by: toduro | last post by:
Sorry about the bad subject line earlier. What is the right syntax for a C++ declaration which would give me __ls__7ostreamPFR7ostream_R7ostream in an object file produced by the gcc 2.95...
49
by: comp.lang.php | last post by:
/** * Class for grayscaling image * * @author Phil Powell * @version 1.2.1 * @package IMAGE_CATALOG::IMAGE */ class ImageGrayscaleGenerator extends ImageResizeComponents { /
1
by: Greg Fuller | last post by:
I'm trying to port a library originally written for unix to Windows. After a bit of work I've finally gotten it to compile and create the ..lib For the purposes of example, let's say the .lib...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.