0
What this code do { global:: . ( obj = value . )
What :: . Works for
6 Respostas
+ 5
Ahmed Faisal I feel like this is turning into a guessing game where I try to answer obscure questions with as little information as possible. 😉
It's okay to provide more context like, which DLL, were you referring to the source code used to compile the DLL or were you referring to the actual compiled DLL? Were you using an ILDASM or reflection to retrieve this code? Is this DLL a System DLL or one you compiled? Can you identify this DLL and could I pull it down to look at?
You have to understand that we're not mind readers and it's a good thing to provide more information. 😉
+ 4
None of that code makes sense.
First, the MccSdk class has 3 invalid private properties.
Property #1 is missing a property name.
Property #2 doesn't specify a type or name. It's like it is using ' . ' as the name.
Property #3 is similar to property #2, but it uses more spaces for the name: ' . '
global:: would normally be used for resolving namespace collision where fully qualifying a namespace would still conflict with an identical namespace nested deeper within another parent namespace.
Example:
1. System.String
2. App.System.String
Referring to System.String could apply to either #1 or #2.
The only way to fully qualify #1 would be global::System.String.
However, that is not what is happening in this code.
Furthermore, the line with global:: . (obj = MccSdk, ref flag) is treating the ' . ' as property #2. It seems as though it should be:
global::MccSdk.some_method(...)
The return statement is all wrong and looks like it's trying to recursively call itself.
+ 3
Where have you seen this code?
+ 3
Also, the return statement in the try block will exit before the finally block can run, unless there is an exception.
I believe the compiler will require the finally block to also have a return statement as well.
Who the heck wrote this and how does it even compile?
0
In dll file
0
It's external library file named MCCsdk.dll for fingerprint matching
This part of code
namespace BioLab.Biometrics.Mcc.Sdk
{
public static class MccSdk
{
// Field with token 04000001
private static object ;
// Field with token 04000002
private static . ;
// Field with token 04000003
private static . ;
[NonSerialized]
public static object CreatePMccTemplate(int imageWidth, int imageHeight, int imageResolution, Minutia[] minutiae)
{
bool flag = false;
object obj;
try
{
global:: . (obj = MccSdk. , ref flag);
return (object) MccSdk. (MccSdk.(imageWidth, imageHeight, imageResolution, minutiae));
}
finally
{
if (flag)
global:: . (obj);
}
}
}}