[
  {
    "Id": "174363",
    "ThreadId": "51975",
    "Html": "Hi all,<br>\r\nI'm hoping somebody has some insight to this problem I'm seeing: I'm using the following code to extract all files into a directory:<br>\r\n<br>\r\n<span style=\"font-size:13px;color:#0000ff\"><span style=\"font-size:13px;color:#0000ff\">\r\n<p>private</p>\r\n</span>\r\n<p>&nbsp;</p>\r\n</span>\r\n<p><span style=\"font-size:13px\"> </span><span style=\"font-size:13px;color:#0000ff\">static</span><span style=\"font-size:13px\"> </span><span style=\"font-size:13px;color:#0000ff\">void</span><span style=\"font-size:13px\"> ExtractZipFiles(</span><span style=\"font-size:13px;color:#2b91af\">TestContext</span><span style=\"font-size:13px\"> context)<br>\r\n{<br>\r\n</span><span style=\"font-size:13px;color:#0000ff\">    try</span><span style=\"font-size:13px\"> <br>\r\n    {<br>\r\n        </span><span style=\"font-size:13px;color:#008000\"><span style=\"font-size:13px;color:#0000ff\">using</span><span style=\"font-size:13px\"> (</span><span style=\"font-size:13px;color:#2b91af\">ZipFile</span><span style=\"font-size:13px\"> zip = </span><span style=\"font-size:13px;color:#2b91af\">ZipFile</span><span style=\"font-size:13px\">.Read(context.TestDeploymentDir + </span><span style=\"font-size:13px;color:#a31515\">&quot;\\\\PrintUnitTest.zip&quot;</span><span style=\"font-size:13px\">))<br>\r\n        </span></span><span style=\"font-size:13px;color:#008000\">{<br>\r\n</span><span style=\"font-size:13px\">            zip.ExtractAll(context.TestDeploymentDir + </span><span style=\"font-size:13px;color:#a31515\">&quot;\\\\&quot;</span><span style=\"font-size:13px\">, </span><span style=\"font-size:13px;color:#0000ff\">true</span><span style=\"font-size:13px\">);<br>\r\n</span><span style=\"font-size:13px;color:#008000\">        }<br>\r\n</span><span style=\"font-size:13px\">    }<br>\r\n</span><span style=\"font-size:13px;color:#0000ff\">    catch</span><span style=\"font-size:13px\"> (System.</span><span style=\"font-size:13px;color:#2b91af\">Exception</span><span style=\"font-size:13px\"> ex1)<br>\r\n    {<br>\r\n        System.</span><span style=\"font-size:13px;color:#2b91af\">Console</span><span style=\"font-size:13px\">.Error.WriteLine(</span><span style=\"font-size:13px;color:#a31515\">&quot;exception: {0}&quot;</span><span style=\"font-size:13px\">, ex1);</span><span style=\"font-size:13px\"><br>\r\n    }<br>\r\n}<br>\r\n<br>\r\nThe code works well running in XP, however it fails in CE!!<br>\r\nThe <strong>ReadCentralDirectoryFooter()</strong> fails because the <strong>EndOfCentralDirectorySignature</strong> that it retrieves is<strong> 0x054b5074</strong> but is expecting <strong>0x06054b50 </strong>at position 0x00073AB6.<br>\r\nAt exactly the same position the code running in XP returns the correct value <span style=\"font-size:13px\"><strong>0x06054b50 </strong>but the code running in CE fails. It seems like it is ONE byte off. As far as I can tell it is the same input ZIP file.<br>\r\n<br>\r\nAny ideas?<br>\r\n<br>\r\nThanks,<br>\r\nMauricio</span>\r\n<p>&nbsp;</p>\r\n</span></p>\r\n",
    "PostedDate": "2009-04-01T08:10:43.687-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "174705",
    "ThreadId": "51975",
    "Html": "THAT is really curious.  One byte off!!<br>\r\n<br>\r\nHmmmmmm.....  Does this happen with every zipfile you try?  <br>\r\nWhat else can you tell me about the zipfile? <br>\r\n<br>\r\nYou said &quot;as far as you can tell it is the same input zip file.&quot;  Can you make sure?  <br>\r\nCan you do a binary compare?  or maybe a checksum on the two files to verify that they are the same and that the one on the CE machine did not get corrupted in some way? <br>\r\n<br>\r\nWhen you say, CE, I that means you are using the compact framework  version of the lib, correct?  <br>\r\nWould it be possible for you to build a test app on XP, linked against the Ionic.Zip.CF.dll, and run it on XP ? <br>\r\n(This will require referencing the CompactFramework assemblies when compiling the desktop app.)  \r\n",
    "PostedDate": "2009-04-02T01:25:54.473-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "174875",
    "ThreadId": "51975",
    "Html": "I noticed that the assembly version is &quot;1.5.0.11&quot; Could that be my problem? Is the Compact Version supported in that version?<br>\r\nDo I have to use 1.7 DotNetZip in order to use the Ionic.Zip.CF.dll? \r\n",
    "PostedDate": "2009-04-02T08:58:40.367-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "174914",
    "ThreadId": "51975",
    "Html": "YES, that could be the problem. <br>\r\nI did not build or test the DotNetZip assembly on CF until v1.7.  <br>\r\n<br>\r\nIt's funny because I was going to ask you what version of the DotNetZip library you were using, but then it occurred to me that you were obviously using v1.7, because that is the only released version that supports .NET CF.<br>\r\n<br>\r\nThe DLL compiled for the desktop .NET Framework includes some calls to methods and classes that do not exist on the .NET CF or on the CE device.  So, for use on .NET CF, you must use the assembly built for CF.<br>\r\n<br>\r\nPlease can you re-test with v1.7 and let me know your results ?<br>\r\n \r\n",
    "PostedDate": "2009-04-02T10:35:05.593-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "174974",
    "ThreadId": "51975",
    "Html": "Thanks, I'll use v1.7 and let you know<br>\r\nMauricio\r\n",
    "PostedDate": "2009-04-02T13:11:33.667-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "176183",
    "ThreadId": "51975",
    "Html": "WOW, lots of new information but not all of it makes sense;<br>\r\n1) I was using the 7-zip v4.57 file archiver application to form the ZIP file the DOTNETZIP lib was trying to extract. I believe 7-zip created a ZIP file that was malformed. If I select 1060 files, right click and create an archive, the ZIP file fails to be extracted in the compact framework by the DotNetZip extractall() method. However, if I create the archive first with a couple of files, and then I add few files at the time until I add all the 1060 files, the resulting ZIP file works well with the DOTNETZIP extractall() method in the Compact Framework. It seems like 7-zip v4.57 is not as robust as it should be.<br>\r\n<br>\r\n2) This is what does not make sense to me. DotNetZip version 1.5.0.11 seems to be working in the Compact Framework. I cannot explain that since CF is no supported until v1.7<br>\r\n<br>\r\nThanks,\r\n",
    "PostedDate": "2009-04-06T09:14:13.777-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "176638",
    "ThreadId": "51975",
    "Html": "hello, Mauricio, <br>\r\n<br>\r\nOn #1, very interesting.   7zip is open source, is that right?  Maybe you could ask them to have a look at that anomalous zip file?   <br>\r\n<br>\r\nOn #2 .  The v1.5.0.11 of DotNetZip was never tested on CF, but it is possible that it worked.  There were things added in later versions, like disposing streams, or setting timestamps on the extracted files, that are not supported directly within CF, and these things will not work.  It is possible though, that the v1.5.0.11 release is safe for CF.  Surprising but possible.<br>\r\n",
    "PostedDate": "2009-04-07T08:00:25.447-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "176863",
    "ThreadId": "51975",
    "Html": "<p>Thanks for your help<br>\r\n<br>\r\nYes 7-zip is open source. I have been looking in their discussion group for similar malformed ZIP files scenarios but I have not found much. But my perception is that it is not quite robust since occasionally I got the MS debugger pop up asking me if I wanted to debug the problem while using the product. <br>\r\n<br>\r\nI'll do what you suggest and contact them. <br>\r\n<br>\r\nv1.5.0.11 seems to be working in CF! Nice job. I may update to 1.7 just to have some peace of mind.</p>\r\n<p> </p>\r\n",
    "PostedDate": "2009-04-07T16:06:29.607-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  }
]