<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi, <br>
    <br>
    write your own small wrapper function with the third parameter which
    translates relative positions to absolute positions. &nbsp; It is not so
    difficult, just a little bit of math (and physfs_tell). The worst is
    probably SEEK_END. If Physfs_uint64 is a problem for you, try a weak
    &amp; dynamic typed language.<br>
    <br>
    On 03.12.2012 19:37, fy wrote:
    <blockquote cite="mid:op.woq7c7sf3gjxnn@xxx-1" type="cite">
      <style type="text/css">body { font-family:'&#23435;&#20307;'; font-size:13px}</style>
      &#22312; Tue, 04 Dec 2012 00:27:45 +0800&#65292;Tim &#268;as
      <a class="moz-txt-link-rfc2396E" href="mailto:darkuranium@gmail.com">&lt;darkuranium@gmail.com&gt;</a> &#20889;&#36947;:<br>
      <br>
      <blockquote style="margin: 0 0 0.80ex; border-left: #0000FF 2px
        solid; padding-left: 1ex">One more thing, which I forgot to
        mention...<br>
        <br>
        ... I don't know whether seeking w/ fseek before the start of
        file is implementation-defined or straight out undefined. In
        either case, the Vorbis API should not be doing the former
        because of portability concerns, and should not be doing the
        latter because, well, it's undefined.<br>
        <br>
        If it's the former (impl-defined) and you're feeling paranoid,
        you can always just do the thing I've specified in the previous
        email -- what's important is that it's consistent.<br>
        If it's the latter (undefined), you don't need to worry about
        handling it at all, since for all the standard cares, it could
        summon (in the case of fseek) nasal demons.<br>
        <br>
        That's in theory anyways -- in practice, as stated, I highly
        doubt the API would do such a nasty thing due to the
        aforementioned reasons.</blockquote>
      <div><br>
      </div>
      <div>OK. Now I tired, but failed.</div>
      <div><br>
      </div>
      <div>Then I load whole file into memory.I got a record of func
        calls by codes of stackoverflow :</div>
      <div><br>
      </div>
      <div>SEEK_END<br>
        SEEK_END<br>
        SEEK_SET<br>
        SEEK_SET</div>
      <div><br>
      </div>
      <div>The "fromwhere" parameter&nbsp;is REALLY&nbsp;needed.</div>
      <div><br>
      </div>
      <div><br>
      </div>
      <div>As&nbsp;to this code snippet,</div>
      <div><br>
      </div>
      <div>&gt; if(type == SEEK_CUR)<br>
        &gt; {<br>
        &gt; if(pos &lt; -diff) // in other words, if `pos + diff` would
        be negative<br>
        &gt; pos = 0;<br>
        &gt; else<br>
        &gt; pos += diff;<br>
        &gt; }</div>
      <div><br>
      </div>
      <div>It can't be so easy.</div>
      <div><br>
      </div>
      <div><br>
      </div>
      <div>Anyway the problem is&nbsp;solved, not in the best way.</div>
      <div><br>
      </div>
      <div>So I think it should be patched.</div>
      <div><br>
      </div>
      <div><br>
      </div>
      <div id="M2Signature">
        <div>-- </div>
        <div>&#20351;&#29992;Opera&#30340;&#30005;&#23376;&#37038;&#20214;&#23458;&#25143;&#31471;&#65306;<a moz-do-not-send="true"
            href="http://www.opera.com/mail/">http://www.opera.com/mail/</a></div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
physfs mailing list
<a class="moz-txt-link-abbreviated" href="mailto:physfs@icculus.org">physfs@icculus.org</a>
<a class="moz-txt-link-freetext" href="http://icculus.org/mailman/listinfo/physfs">http://icculus.org/mailman/listinfo/physfs</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>