File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -28,4 +28,9 @@ public static string GetFileName(this IRarHeader header)
2828 {
2929 return ( string ) header . GetReflectionProperty ( "FileName" ) ! ;
3030 }
31+
32+ public static bool IsDirectory ( this IRarHeader header )
33+ {
34+ return ( bool ) header . GetReflectionProperty ( "IsDirectory" ) ! ;
35+ }
3136}
Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ private List<IRarHeader> GetRarHeaders(Stream stream)
9595 foreach ( var header in headerFactory . ReadHeaders ( stream ) )
9696 {
9797 // we only care about file headers
98- if ( header . HeaderType != HeaderType . File || header . GetFileName ( ) == "QO" ) continue ;
98+ if ( header . HeaderType != HeaderType . File || header . IsDirectory ( ) || header . GetFileName ( ) == "QO" ) continue ;
9999
100100 // we only support stored files (compression method m0).
101101 if ( header . GetCompressionMethod ( ) != 0 )
You can’t perform that action at this time.
0 commit comments