Opened 19 years ago
Closed 18 years ago
#4 closed task (fixed)
Update assocation logic to allow multiple dots and longer extensions
| Reported by: | dwgras | Owned by: | Gregg Young |
|---|---|---|---|
| Priority: | major | Milestone: | Release_3.8 |
| Component: | fm/2 base | Version: | 3.08 |
| Keywords: | Cc: | dwgras@… |
Description
Allow for more than 1 extension and more than 3 characters in extensions
Change History (11)
comment:1 by , 19 years ago
comment:2 by , 19 years ago
| Owner: | changed from to |
|---|
New flag for associations related to length from final period.
0 - no period strnchar \ to cut filename then strnchar . = null 1 - period followed by nothing or wild card cut filename token on . use final token strlen = 1 2 - period followed by 1 char same as 1 but strlens = 2 3-100 same as above (no number limit imposed)
string compare (no case) to association filemask 0s & 1s would be comp to masks of style "xxx" "xxx." "xxx.*" after dropping the '.' & '*' from all strings.
Need to handle xxx* mask strcpy filename to string of strlen = mask - 1 run against all filenames
string compare for .xxx final token from above (extension of any length) would drop use strlens then compare to the appropriate flag numbered filemasks *xxx would be handled by replacing the '*' with a '.'
Assumptions
- Final extension is the file type indicator as opposed to first extention
- Associations by filename should be allowed including allowing wild card extensions
- Compare would be done directly on any filenames without wildcards
- Wildcards only at beginning and end. Could handle ones in the middle but do we need to?
- Arbitrarily long extensions permitted
- Exact matchs
comment:3 by , 19 years ago
| Status: | new → assigned |
|---|
comment:4 by , 19 years ago
| Status: | assigned → new |
|---|
comment:5 by , 19 years ago
| Summary: | Update assocation logic → Update assocation logic to allow multiple dots and longer extensions |
|---|
comment:6 by , 19 years ago
| Reporter: | changed from to |
|---|
comment:7 by , 19 years ago
| Owner: | removed |
|---|
comment:8 by , 18 years ago
| Milestone: | → Release_3.8 |
|---|---|
| Version: | → 3.08 |
comment:9 by , 18 years ago
| Owner: | set to |
|---|
comment:10 by , 18 years ago
| Status: | new → assigned |
|---|
comment:11 by , 18 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |

The limitation is in filldir.c IDFile(). The code is pretty primitive. It supports only 3 character extensions for a fixed number of file types and there is not way to make this more flexible without a complete rewrite.