Jump to content

Welcome to MSFN Forum
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account


Photo

Strange bug in HFSLIP related to short 8.3 names

- - - - -

  • Please log in to reply
2 replies to this topic

#1
tomasz86

tomasz86

    www.windows2000.tk

  • Member
  • PipPipPipPipPipPipPipPip
  • 2,520 posts
  • OS:XP Pro x86
  • Country: Country Flag
I found a very strange bug and don't really know why it occurs. I do know how to fix it though.

  • In the HFSLIP's script you can find the following lines:

    ECHO.&ECHO Locating compressed files in I386 subfolders
    SET BASEDIR=%~dp0SOURCESS\I386\
    DIR/B/AD SOURCESS\I386>WORK\SSSI386SUB0.TXT
    FINDSTR/VBI "SVCPACK" WORK\SSSI386SUB0.TXT>WORK\SSSI386SUB.TXT
    FOR /F "DELIMS=" %%Z IN (WORK\SSSI386SUB.TXT) DO DIR/B/S/A-D/ON "SOURCESS\I386\%%Z">>WORK\SSSI386SUBALL.TXT
  • Add a PAUSE at the end of it:

    ECHO.&ECHO Locating compressed files in I386 subfolders
    SET BASEDIR=%~dp0SOURCESS\I386\
    DIR/B/AD SOURCESS\I386>WORK\SSSI386SUB0.TXT
    FINDSTR/VBI "SVCPACK" WORK\SSSI386SUB0.TXT>WORK\SSSI386SUB.TXT
    FOR /F "DELIMS=" %%Z IN (WORK\SSSI386SUB.TXT) DO DIR/B/S/A-D/ON "SOURCESS\I386\%%Z">>WORK\SSSI386SUBALL.TXT
    PAUSE
  • Now run the script. After it has paused, open the "WORK\SSSI386SUBALL.TXT" file. It will look like this:

    R:\HFSLIP_test1\SOURCESS\I386\COMPDATA\3COM.HTM
    R:\HFSLIP_test1\SOURCESS\I386\COMPDATA\3COM.TXT
    R:\HFSLIP_test1\SOURCESS\I386\COMPDATA\AACRAID.HTM
    R:\HFSLIP_test1\SOURCESS\I386\COMPDATA\AACRAID.TXT
    R:\HFSLIP_test1\SOURCESS\I386\COMPDATA\ACCELPRO.HTM
    etc.
  • Download one of the OnePiece's .NET Framework addons, ex. Onepiece's Microsoft .NET Framework 1.1 SP1 for Windows 2000 with GDR updates TRUE Addon and place it in HFAAO (you may need to rename it to something shorter, ex. "NETFX20.CAB").
  • Run the script again and wait until it has paused.
  • Check "WORK\SSSI386SUBALL.TXT" again. It will look like this:

    R:\HFSLIP~1\SOURCESS\I386\COMPDATA\3COM.HTM
    R:\HFSLIP~1\SOURCESS\I386\COMPDATA\3COM.TXT
    R:\HFSLIP~1\SOURCESS\I386\COMPDATA\AACRAID.HTM
    R:\HFSLIP~1\SOURCESS\I386\COMPDATA\AACRAID.TXT
    R:\HFSLIP~1\SOURCESS\I386\COMPDATA\ACCELPRO.HTM
    etc.
    For some reason the short names are used and I can't figure out why (the switched used is just a standard "DIR/B/S/ON").

Now the real problem is that this completely breaks updating files from the I386\UNIPROC folder which happens later. The files located in in I386\UNIPROC are the following ones (in Win2k):

KERNEL32.DL_
MP2UP.CAT
MP2UP.INF
NTDLL.DLL
WIN32K.SY_
WINSRV.DL_
Normally HFSLIP should just update them with the newer versions. Now when the problem from 6) occurs they are not updated. After the script finishes the folder looks like this:

KERNEL32.DLL
KERNEL32.DL_
MP2UP.CAT
MP2UP.INF
NTDLL.DLL
WIN32K.SYS
WIN32K.SY_
WINSRV.DLL
WINSRV.DL_
The first KERNEL32.DLL is the newly added file while KERNEL32.DL_ is the original one. Unfortunately Windows setup installs the latter which means that the new version is not installed.

I don't know why such a strange bug occurs but I do know how to fix it. The following line:

FOR /F "DELIMS=" %%Z IN (WORK\SSSI386SUB.TXT) DO DIR/B/S/A-D/ON "SOURCESS\I386\%%Z">>WORK\SSSI386SUBALL.TXT
must be changed to:

FOR /F "DELIMS=" %%Z IN (WORK\SSSI386SUB.TXT) DO DIR/B/S/A-D/ON "%~dp0SOURCESS\I386\%%Z">>WORK\SSSI386SUBALL.TXT

I would call this bug critical and want to ask for a quick fix (Mim0?) because this completely breaks Win2k installation.
Posted Image
Unofficial Service Pack 5.2 for MS Windows 2000 <- use this topic if you need help with UURollup, Update Rollup 2 and other unofficial packages


How to remove advertisement from MSFN

#2
tomasz86

tomasz86

    www.windows2000.tk

  • Member
  • PipPipPipPipPipPipPipPip
  • 2,520 posts
  • OS:XP Pro x86
  • Country: Country Flag
Something seems to get broken at this stage of integrating addons:

Spoiler

Posted Image
Unofficial Service Pack 5.2 for MS Windows 2000 <- use this topic if you need help with UURollup, Update Rollup 2 and other unofficial packages

#3
tomasz86

tomasz86

    www.windows2000.tk

  • Member
  • PipPipPipPipPipPipPipPip
  • 2,520 posts
  • OS:XP Pro x86
  • Country: Country Flag
I've finally managed to find the culprit!

Using "extract.exe" causes to unpack CAB addons causes the CMD window to use short names. "Extract.exe" is used by HFSLIP only once which is when unpacking CAB addons:

This is the full code
FOR /F "DELIMS=" %%I IN ('DIR/B/A-D/ON HFAAO') DO (
	IF /I "%%~xI"==".rar" IF EXIST HFTOOLS\RAR.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\RAR e "HFAAO\%%I" * "%PREP%TEMP\AAO\" >NUL&&CALL :PROCESS_AAO
	IF /I "%%~xI"==".cab" IF EXIST HFTOOLS\EXTRACT.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\EXTRACT /E /L TEMP\AAO "HFAAO\%%I" >NUL&&CALL :PROCESS_AAO
	IF /I NOT "%%~xI"==".rar" IF /I NOT "%%~xI"==".cab" (
		IF EXIST HFTOOLS\7ZA.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\7ZA x "HFAAO\%%I" -o"%PREP%TEMP\AAO" -r >NUL&&CALL :PROCESS_AAO
	)
)

After removing parts not related to CAB addons:
FOR /F "DELIMS=" %%I IN ('DIR/B/A-D/ON HFAAO') DO (
	IF /I "%%~xI"==".cab" IF EXIST HFTOOLS\EXTRACT.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\EXTRACT /E /L TEMP\AAO "HFAAO\%%I" >NUL&&CALL :PROCESS_AAO
)

The problem lies here:

HFTOOLS\EXTRACT /E /L TEMP\AAO "HFAAO\%%I"

I did a simple test doing:

DIR/B/S HFAAO
before and after extracting a CAB addon. The result was:

1. Before:

D:\HFSLIP\TEMP\HFSLIP_test\HFAAO\NETFX11.cab
2. After:

D:\HFSLIP\TEMP\HFSLIP~2\HFAAO\NETFX11.cab
"HFSLIP_test" got changed into "HFSLIP~2" and this causes all the issues which I described in this topic above.


The solution to this problem is very simple. Remove this line all together:

IF /I "%%~xI"==".cab" IF EXIST HFTOOLS\EXTRACT.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\EXTRACT /E /L TEMP\AAO "HFAAO\%%I" >NUL&&CALL :PROCESS_AAO

and change the next one from

IF /I NOT "%%~xI"==".rar" IF /I NOT "%%~xI"==".cab" (
to

IF /I NOT "%%~xI"==".rar" (
so that the result should be

FOR /F "DELIMS=" %%I IN ('DIR/B/A-D/ON HFAAO') DO (
	IF /I "%%~xI"==".rar" IF EXIST HFTOOLS\RAR.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\RAR e "HFAAO\%%I" * "%PREP%TEMP\AAO\" >NUL&&CALL :PROCESS_AAO
	IF /I NOT "%%~xI"==".rar" (
		IF EXIST HFTOOLS\7ZA.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\7ZA x "HFAAO\%%I" -o"%PREP%TEMP\AAO" -r >NUL&&CALL :PROCESS_AAO
	)
)
7-Zip is capable of unpacking CABs so there's no need to use the outdated "extract.exe". In fact, at this point I'd suggest removing the RAR part too, leaving just

FOR /F "DELIMS=" %%I IN ('DIR/B/A-D/ON HFAAO') DO (
	IF EXIST HFTOOLS\7ZA.EXE ECHO.&&ECHO Processing %%I&&HFTOOLS\7ZA x "HFAAO\%%I" -o"%PREP%TEMP\AAO" -r >NUL&&CALL :PROCESS_AAO
)
since 7-Zip can process RAR too.

Edited by tomasz86, 19 June 2013 - 12:30 PM.

Posted Image
Unofficial Service Pack 5.2 for MS Windows 2000 <- use this topic if you need help with UURollup, Update Rollup 2 and other unofficial packages




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users



How to remove advertisement from MSFN