rejetto forum

Software => HFS ~ HTTP File Server => Bug reports => Topic started by: skb on January 08, 2017, 05:14:41 AM

Title: Standard Template rename does funny things with $ before numbers in new name
Post by: skb on January 08, 2017, 05:14:41 AM
Not really debugged this at all yet; I've merely noticed it in my modified version of the standard template, and then restore the default one to confirm it wasn't just me.

If a file name includes numbers, and you rename it to insert a "$" before those numbers, the $ and some numbers are deleted from the name.

The specific example I found was attempting to rename the file name "SCS_A01_10039.CSV" to "SCS_A01_$10039.CSV".

The resulting file name became: "SCS_A01_039.CSV".  That is, the "$10" was deleted from the new name.

"$" works fine in other parts of the string, but before a digit 1-9, the $ and one or two digits are removed.

Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: Mars on January 08, 2017, 11:47:07 PM
The origin of the problem is identified, a study is under way to apply a durable solution, there is only to wait for a new update

Be patient, very patient
Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: skb on January 09, 2017, 04:41:36 AM
Thanks for the speedy reply, and for all your work on HFS!

No rush on the fix, as it's really no big deal: a minor bug that's hard to trigger in real life! (I was doing this manual rename to make test file for a new feature, and in my production version such renames won't be needed.) 

Or, if necessary, I can use a different "flag" character in the data file name than "$".

Cheers, Steve
Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: Mars on January 09, 2017, 01:49:11 PM
Only strings of characters $01  to $40 are affected by this problem,

the error does not only affect the name of the files but all that corresponds to all the macros of type ALIAS of the form {.^xxxxx.}

In your case, renaming the file SCS_A01_10039.CSV to SCS_A01_$10039.CSV give the result SCS_A01_039.CSV, attempting to rename SCS_A01_039.CSV with SCS_A01_$01039.CSV to SCS_A01_$40039.CSV will always give an error because the generated name is the same.


Using the {.EXISTS | SCS_A01_ $ 10039.CSV.} Returns the Boolean value TRUE because the real name tested equal to SCS_A01_039.CSV.
Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: rejetto on February 04, 2017, 07:01:52 PM
i'm working on this. I'll let you know.
Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: rejetto on February 13, 2017, 10:19:48 PM
the fix for this bug will be included in next release, 2.3j

i hope to publish it soon
Title: Re: Standard Template rename does funny things with $ before numbers in new name
Post by: Fysack on September 30, 2017, 11:07:29 PM
you are so lucky skb. peace n love.  ;D yea man, top noch of the world having fun  ;D ;D ;D ;D