Search Results

Search found 8 results on 1 pages for 'dbger'.

Page 1/1 | 1 

  • How to use an out-of-process COM server without its tlb file

    - by Dbger
    It is about Window COM component. Server.exe: an 32bit out-of-process COM server CLSID_Application: The GUID of a COM object in Server.exe Client.exe: a 64bit client application which use Server.exe in a registry-free way. As we know, an exe can't be used as a registry-free COM component, to mimic such behavior, I start the Server.exe process myself by providing the exact path: CreateProcess("Server.exe") IClassFactory* pFactory = CoGetClassObject(CLSID_Application) pFactory-CreateInstance(ppAppObject); It works if I have the Server.tlb registred, but after unregister Server.tlb, it just failed to create the ppAppObject, even though I embed manifest into both Server.exe and Client.exe: <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> <file name="Server.tlb"> <typelib tlbid="{DAC4A4C9-F84C-4F05-A7DC-E152869499F5}" version="1.0" helpdir=""></typelib> </file> <comInterfaceExternalProxyStub name="IApplication" iid="{D74208EA-71C2-471D-8681-9760B8ECE599}" tlbid="{DAC4A4C9-F84C-4F05-A7DC-E152869499F5}" proxyStubClsid32="{00020424-0000-0000-C000-000000000046}"></comInterfaceExternalProxyStub> </assembly> Do you have any idea on this? Edit: It turns out that it really works if I specify tlbid for interfaces, and embed the manifest to both exe

    Read the article

  • Why Read In UTF-16LE File Won't Convert "\r\n" Into "\n" In Windows

    - by Dbger
    I am using Perl to read UTF-16LE files in Windows 7. If I read in an ascii file with following code: open CUR_FILE, "<", $asciiFile; Then each "\r\n" in file will be converted into a "\n" in memory; if I read in an UTF-16LE(windows 1200) file with following code: open CUR_FILE, "<:encoding(UTF-16LE)", $utf16leFile; Then "\r\n" will keep unchanged. This inconsistency cause problems when I trying to regexp lines with line breaks. My questions is: Is this how unicode works in Perl & Windows? Or Am I using the wrong code? Thanks so much!

    Read the article

  • Does negate twice (!!) make any sense?

    - by Dbger
    I noticed following usage of negate (!) in our code base, like: int GetIntFromRegistry(); bool bok = !!GetIntFromRegistry(); I am really curious about the usage of !!, it you want to cast the type from int to bool, why not just cast it explicitly use (bool), or static_cast. Is there anything I am missing?

    Read the article

  • Are weekly reports necessary?

    - by Dbger
    At the times that we didn't use Scrum, we had weekly status meeting and technical discussion; And now after we adopt Scrum, we have daily stand up meeting. But for both cases, weekly reports are always a necessity, although I don't see much value of doing this in our development team. What do you think of weekly report? what benefit that you got from it if your like it?

    Read the article

  • What is the trick in pAddress & ~(PAGE_SIZE - 1) to get the page's base address

    - by Dbger
    Following function is used to get the page's base address of an address which is inside this page: void* GetPageAddress(void* pAddress) { return (void*)((ULONG_PTR)pAddress & ~(PAGE_SIZE - 1)); } But I couldn't quite get it, what is the trick it plays here? Conclusion: Personally, I think Amardeep's explanation plus Alex B's example are best answers. As Alex B's answer has already been voted up, I would like to accept Amardeep's answer as the official one to highlight it! Thanks you all.

    Read the article

1