------------------------------------------------------------
                        [BUG/PRB.] VFP 9.0 FIX - FULLPATH() FUNCTION
                                 January 2024
                 ------------------------------------------------------------
                                     CCB



1. BUG:

     In vfp9 (and vfp6, vfp7, vfp8), sometimes the FULLPATH("") function returns wrong result.


2. CAUSE:

     There are some BUGs in the following code.


3. RESOLUTION:

     We can write some code to fix the BUG.

     Fun435040 :: ; proc near
             cmp  byte ptr [esi] , 05Ch                                      ;0x00435040 :        803e5c
             je Label598a95                                                  ;0x00435043 :        0f844c3a1600


     ;
     ;                 -------------------------------------------------
     ;                        VFP 9.0 FIX - FULLPATH() FUNCTION
     ;                                November 2023
     ;                 -------------------------------------------------
     ;                                     CCB
     ;
     ; In vfp9, sometimes the FULLPATH("") function returns wrong result.
     ;
     ; 2023/11/19, by ccb
     ;

             cmp  byte ptr [esi] , 00h
             je Label435052


     Label435049 ::
             cmp  byte ptr [ esi + 1 ] , 03Ah                                ;0x00435049 :        807e013a
             lea eax ,  dword ptr [ esi + 2 ]                                ;0x0043504d :        8d4602
             je Label435054                                                  ;0x00435050 :        7402

     Label435052 ::
             mov eax , esi                                                   ;0x00435052 :        8bc6

     Label435054 ::
             ret                                                             ;0x00435054 :        c3


4. APPLIES TO:

     VFP 6.0.8167.0
     VFP 6.0.8961.0 (SP5)

     VFP 7.0.0.9262
     VFP 7.0.0.9465 (SP1)

     VFP 8.0.0.2521
     VFP 8.0.0.3117 (SP1)

     VFP 9.0.0.2412
     VFP 9.0.0.3504 (SP1)
     VFP 9.0.0.4611 (SP2)
     VFP 9.0.0.5015 (SP2)
     VFP 9.0.0.5411 (SP2)
     VFP 9.0.0.5721 (SP2)
     VFP 9.0.0.5815 (SP2)
     VFP 9.0.0.6303 (SP2)
     VFP 9.0.0.6602 (SP2)
     VFP 9.0.0.7423 (SP2)

     The bug has been fixed in VFP Advanced.


5. REFERENCE WEBSITES:

     1, baiyujia.com:
     http://www.baiyujia.com
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix100.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix102.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix103.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix354.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix355.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix356.asp
     http://www.baiyujia.com/vfpdocuments/f_vfp9fix357.asp


6. OTHER:

     For reference only, there is no guarantees.

     Any questions or suggestions, please send me an email at ccb2000@163.com.