TclVFS

Check-in [811432f961]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:2013-02-05 Wojciech Kocjan <[email protected]> * library/zipvfs.tcl: vfs::zip unable to read zip archives with wrong modes, bug 3603414
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 811432f961cb96fd69fc4118de18fa0fe29ee0a8
User & Date: zoro2 2013-02-05 13:18:48.000
Context
2014-04-16
02:42
Added the correct EXPORT and DLLEXPORT directives to make the package loadable once more check-in: 2fec87c76b user: seandeelywoods tags: etoyoc
2014-03-10
11:39
Fix for zipvfs not preserving missing directories' upper case characters. check-in: b3589b4476 user: zoro2 tags: trunk
2013-02-05
13:18
2013-02-05 Wojciech Kocjan <[email protected]> * library/zipvfs.tcl: vfs::zip unable to read zip archives with wrong modes, bug 3603414 check-in: 811432f961 user: zoro2 tags: trunk
2012-12-12
21:41
* library/template/collatevfs.tcl: Added missing provide command. * library/template/templatevfs.tcl: Fixed missing default status 0 in * pkgIndex.tcl.in: overriden exit command. Bumped to 1.5.5 check-in: a54d27c344 user: andreas_kupries tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to library/zipvfs.tcl.
69
70
71
72
73
74
75
76
77
78












79
80
81
82
83
84
85
    return $newres
}

proc vfs::zip::stat {zipfd name} {
    #::vfs::log "stat $name"
    ::zip::stat $zipfd $name sb
    #::vfs::log [array get sb]
    # remove socket mode bit (0xc000) to prevent Tcl from reporting Fossil archives as socket types
    if {($sb(mode) & 0xc000) == 0xc000} {
        set sb(mode) [expr {$sb(mode) ^ 0xc000}]












    }
    array get sb
}

proc vfs::zip::access {zipfd name mode} {
    #::vfs::log "zip-access $name $mode"
    if {$mode & 2} {







|
|

>
>
>
>
>
>
>
>
>
>
>
>







69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
    return $newres
}

proc vfs::zip::stat {zipfd name} {
    #::vfs::log "stat $name"
    ::zip::stat $zipfd $name sb
    #::vfs::log [array get sb]
    # remove socket mode file type (0xc000) to prevent Tcl from reporting Fossil archives as socket types
    if {($sb(mode) & 0xf000) == 0xc000} {
        set sb(mode) [expr {$sb(mode) ^ 0xc000}]
    }
    # remove block device bit file type (0x6000)
    if {($sb(mode) & 0xf000) == 0x6000} {
        set sb(mode) [expr {$sb(mode) ^ 0x6000}]
    }
    # remove FIFO mode file type (0x1000)
    if {($sb(mode) & 0xf000) == 0x1000} {
        set sb(mode) [expr {$sb(mode) ^ 0x1000}]
    }
    # remove character device mode file type (0x2000)
    if {($sb(mode) & 0xf000) == 0x2000} {
        set sb(mode) [expr {$sb(mode) ^ 0x2000}]
    }
    array get sb
}

proc vfs::zip::access {zipfd name mode} {
    #::vfs::log "zip-access $name $mode"
    if {$mode & 2} {