Announcement

Collapse
No announcement yet.

msvcrt.dll

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • msvcrt.dll

    I have tried to make a very small nsis script for upgrading a dll (msvcrt.dll). I use the macro UpgradeDLL from the documentation (Useful function, B.10). I can see in the registry that a pending rename function is inserted. Its intensions seems to be right. The syntax is a little cryptic (some ?? and a !).

    I do not see any effect, the old msvcrt.dll version is kept.

    I have tried to enable boot-logging, but I see nothing there.

    I am using Windows 2000, and NSIS v2.0b0

    Best regards,
    Jan Eggert Kofoed

  • #2
    Please attach the script and the registry key that is written (just copy and paste it).
    NSIS FAQ | NSIS Home Page | Donate $
    "I hear and I forget. I see and I remember. I do and I understand." -- Confucius

    Comment


    • #3
      My script is as follows
      -----------------------
      !include jk.txt
      Name "FORCE Technology (jk's test)"
      InstallDir "c:\Programs\SimFlexNavigator"
      OutFile jk.exe
      Section ""
      SetOutPath $INSTDIR
      !insertmacro UpgradeDLL "msvcrt.dll" "$SYSDIR\msvcrt.dll"
      SectionEnd
      ------------------------
      I have a copy of msvcrt.dll where I run the scipts. I can see that the correct file is stored in the temp-directory.
      With REGEDIT I find
      Folder: My Computer/HKLM/SYSTEM/ControlSet001/Control/Session Manager
      Name : PendingFileRenameOperations
      Type : REG_MULTI_SZ
      Data : \??\C:\DOCUME~1\ADMIN~1.PC0\LOCALS~1\Temp\nst1.tmp !\??\C:\WINNT\System32\msvcrt.dll
      (Data is one long line).

      Thank you very much for your quick respons.

      Best regards,
      Jan

      Comment


      • #4
        Is the temporary file deleted or does it stay in $TEMP?

        BTW, that cryptic syntax is for NT's long paths.
        NSIS FAQ | NSIS Home Page | Donate $
        "I hear and I forget. I see and I remember. I do and I understand." -- Confucius

        Comment


        • #5
          The file IS deleted from $TEMP, and the pending file rename is removed from the registry, so an attempt IS being made. I don't know whether the dll is locked very early on in the boot sequence.

          (What I found cryptic was the use of ? and ! :-)

          Comment


          • #6
            I will test this later on my computer. For now, try using the latest CVS version.
            NSIS FAQ | NSIS Home Page | Donate $
            "I hear and I forget. I see and I remember. I do and I understand." -- Confucius

            Comment


            • #7
              Thanx again for your very fast replies!!!

              I have downloaded "Development Snapshot" dated 20020127 (i.e. today), and built all three projects, using the new version of makensis.exe and created a new installation (jk.exe). I get the same result.
              The existing dll in c:/winnt/system32 is from May 2001, version 6.1.8924.0
              The file nst1.tmp placed in (and subsequently removed from) $TEMP is version 6.1.9359.0

              Best regards,
              Jan

              Comment


              • #8
                The file is probably protected by Windows File Protection, so you can't upgrade it. Only Microsoft Service Packs can upgrade it.

                Comment

                Working...
                X