<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: help: different OPEN  extended modes in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145675#M39324</link>
    <description>Well, the c-rtl has a freopen call.&lt;BR /&gt;But best I can tell that just does a close + open.&lt;BR /&gt;In which case I would prefer the explicit close+open.&lt;BR /&gt;&lt;BR /&gt;What are you worried about? One extra file open for a file which header and data are in the XQP and XFC caches? 'cleanliness'?&lt;BR /&gt;&lt;BR /&gt;Just FYI... it is NOT going to be as easy as chasing down the file pointer and flipping a bit or two. A lot of the C-rtl internal control block changes when flipping this. Some stays (fab, rab)...&lt;BR /&gt;&lt;BR /&gt;  1602: fp = fopen( argv[1], "r", "ctx=stm" );&lt;BR /&gt;DBG&amp;gt; s&lt;BR /&gt;stepped to SCF\main\%LINE 1603&lt;BR /&gt;  1603: return (fclose ( fp ));&lt;BR /&gt;DBG&amp;gt; set rad hex&lt;BR /&gt;DBG&amp;gt; ex/octaw @@fp:(@@fp)+70&lt;BR /&gt;0000000000664BB0:       0004034900668000 0066800000000216&lt;BR /&gt;0000000000664BC0:       400040000066C000 0066800000000003&lt;BR /&gt;0000000000664BD0:       0000000000000000 0000000000667610&lt;BR /&gt;0000000000664BE0:       0000000000000216 0000000000000000&lt;BR /&gt;0000000000664BF0:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C00:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C10:       0000000000000000 000000000066DE10&lt;BR /&gt;0000000000664C20:       006675A000664D10 006675F000000000&lt;BR /&gt;&lt;BR /&gt;DBG&amp;gt; ex/asciz 000000000066DE10&lt;BR /&gt;000000000066DE10:       "TMP.COM"&lt;BR /&gt;&lt;BR /&gt;SDA&amp;gt; show proc/rms=(rab,fab)&lt;BR /&gt;FAB Address:    00664D10          &lt;BR /&gt;RAB Address:    006675A0   &lt;BR /&gt;    &lt;BR /&gt;  1602: fp = fopen( argv[1], "r", "ctx=bin" );&lt;BR /&gt;DBG&amp;gt; s&lt;BR /&gt;stepped to SCF\main\%LINE 1603&lt;BR /&gt;  1603: return (fclose ( fp ));&lt;BR /&gt;DBG&amp;gt; set rad hex&lt;BR /&gt;DBG&amp;gt; ex/octaw @@fp:(@@fp)+70&lt;BR /&gt;0000000000664BB0:       000003490066E000 0066E00000000013&lt;BR /&gt;0000000000664BC0:       7FFF800000676000 0066E00000000003&lt;BR /&gt;0000000000664BD0:       0FFFFFFFF00000000 000000000066DE20&lt;BR /&gt;0000000000664BE0:       0000000000000016 0000000100000000&lt;BR /&gt;0000000000664BF0:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C00:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C10:       0000000000000000 000000000066DE10&lt;BR /&gt;0000000000664C20:       006675A000664D10 006675F000000000&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;fwiw,&lt;BR /&gt;Hein.&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Sat, 16 Feb 2008 02:47:30 GMT</pubDate>
    <dc:creator>Hein van den Heuvel</dc:creator>
    <dc:date>2008-02-16T02:47:30Z</dc:date>
    <item>
      <title>help: different OPEN  extended modes</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145672#M39321</link>
      <description>Hello!&lt;BR /&gt;During porting clamav I just get a trouble:&lt;BR /&gt;&lt;BR /&gt;...&lt;BR /&gt;...&lt;BR /&gt;des = open(file, mode, right, "ctx=bin");&lt;BR /&gt;...&lt;BR /&gt;...&lt;BR /&gt;&lt;BR /&gt;then code analyzes file content and choose the one of the scanner ( zip, arj, html, etc.)&lt;BR /&gt;&lt;BR /&gt;The problem lies in the fact that one of the file type (html) should be opened with&lt;BR /&gt;"ctx=stm","rfm=stmlf"&lt;BR /&gt;&lt;BR /&gt;What can I do when the file has been opened yet as "ctx=bin". How can I "reopen" file by his descriptor with new attributes?&lt;BR /&gt;I have a variant: save scanning file name to the external variable and close then open file with new attributes, but I dont like it - not estetic and broke logic of the program.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 15 Feb 2008 11:10:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145672#M39321</guid>
      <dc:creator>Alex Chupahin</dc:creator>
      <dc:date>2008-02-15T11:10:15Z</dc:date>
    </item>
    <item>
      <title>Re: help: different OPEN  extended modes</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145673#M39322</link>
      <description>&lt;!--!*#--&gt;Why don't you use "ctx=stm","rfm=stmlf"&lt;BR /&gt;always?  I would expect UNIXy programs not&lt;BR /&gt;to care.  For example, UnZip doesn't seem to&lt;BR /&gt;care:&lt;BR /&gt;&lt;BR /&gt;alp $ zip fred.zip *.pdf&lt;BR /&gt;  adding: CLEAR_SEL__13421.PDF (deflated 50%)&lt;BR /&gt;  adding: ZX2000_GETTING_STARTED.PDF (deflated 1%)&lt;BR /&gt;  adding: ZX2000_QUICK_SETUP.PDF (deflated 2%)&lt;BR /&gt;  adding: ZX2000_TECH_REF.PDF (deflated 3%)&lt;BR /&gt;&lt;BR /&gt;alp $ pipe dire /full fred.zip | sear sys$input "record "&lt;BR /&gt;Record format:      Fixed length 512 byte records&lt;BR /&gt;Record attributes:  None&lt;BR /&gt;&lt;BR /&gt;alp $ set file /attr = rfm:stmlf fred.zip&lt;BR /&gt;&lt;BR /&gt;alp $ pipe dire /full fred.zip | sear sys$input "record "&lt;BR /&gt;Record format:      Stream_LF, maximum 512 bytes, longest 512 bytes&lt;BR /&gt;Record attributes:  None&lt;BR /&gt;&lt;BR /&gt;alp $ unzip -t fred.zip&lt;BR /&gt;Archive:  ALP$DKA0:[SMS.ZX2000]FRED.ZIP;1&lt;BR /&gt;    testing: clear_sel__13421.pdf     OK&lt;BR /&gt;    testing: zx2000_getting_started.pdf   OK&lt;BR /&gt;    testing: zx2000_quick_setup.pdf   OK&lt;BR /&gt;    testing: zx2000_tech_ref.pdf      OK&lt;BR /&gt;No errors detected in compressed data of ALP$DKA0:[SMS.ZX2000]FRED.ZIP;1.</description>
      <pubDate>Fri, 15 Feb 2008 13:46:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145673#M39322</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2008-02-15T13:46:30Z</dc:date>
    </item>
    <item>
      <title>Re: help: different OPEN  extended modes</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145674#M39323</link>
      <description>&amp;gt; Why don't you use "ctx=stm","rfm=stmlf"&lt;BR /&gt;&lt;BR /&gt;No.&lt;BR /&gt;I'm mantain porting clamav for 2 years and research many sides of the various problems with it.&lt;BR /&gt;&lt;BR /&gt;for archives the best should be ctx=bin,&lt;BR /&gt;for html should be "ctx=stm","rfm=stmlf"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;So I should "reopen" file with new mode.&lt;BR /&gt;Can I do that?&lt;BR /&gt;</description>
      <pubDate>Fri, 15 Feb 2008 18:12:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145674#M39323</guid>
      <dc:creator>Alex Chupahin</dc:creator>
      <dc:date>2008-02-15T18:12:29Z</dc:date>
    </item>
    <item>
      <title>Re: help: different OPEN  extended modes</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145675#M39324</link>
      <description>Well, the c-rtl has a freopen call.&lt;BR /&gt;But best I can tell that just does a close + open.&lt;BR /&gt;In which case I would prefer the explicit close+open.&lt;BR /&gt;&lt;BR /&gt;What are you worried about? One extra file open for a file which header and data are in the XQP and XFC caches? 'cleanliness'?&lt;BR /&gt;&lt;BR /&gt;Just FYI... it is NOT going to be as easy as chasing down the file pointer and flipping a bit or two. A lot of the C-rtl internal control block changes when flipping this. Some stays (fab, rab)...&lt;BR /&gt;&lt;BR /&gt;  1602: fp = fopen( argv[1], "r", "ctx=stm" );&lt;BR /&gt;DBG&amp;gt; s&lt;BR /&gt;stepped to SCF\main\%LINE 1603&lt;BR /&gt;  1603: return (fclose ( fp ));&lt;BR /&gt;DBG&amp;gt; set rad hex&lt;BR /&gt;DBG&amp;gt; ex/octaw @@fp:(@@fp)+70&lt;BR /&gt;0000000000664BB0:       0004034900668000 0066800000000216&lt;BR /&gt;0000000000664BC0:       400040000066C000 0066800000000003&lt;BR /&gt;0000000000664BD0:       0000000000000000 0000000000667610&lt;BR /&gt;0000000000664BE0:       0000000000000216 0000000000000000&lt;BR /&gt;0000000000664BF0:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C00:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C10:       0000000000000000 000000000066DE10&lt;BR /&gt;0000000000664C20:       006675A000664D10 006675F000000000&lt;BR /&gt;&lt;BR /&gt;DBG&amp;gt; ex/asciz 000000000066DE10&lt;BR /&gt;000000000066DE10:       "TMP.COM"&lt;BR /&gt;&lt;BR /&gt;SDA&amp;gt; show proc/rms=(rab,fab)&lt;BR /&gt;FAB Address:    00664D10          &lt;BR /&gt;RAB Address:    006675A0   &lt;BR /&gt;    &lt;BR /&gt;  1602: fp = fopen( argv[1], "r", "ctx=bin" );&lt;BR /&gt;DBG&amp;gt; s&lt;BR /&gt;stepped to SCF\main\%LINE 1603&lt;BR /&gt;  1603: return (fclose ( fp ));&lt;BR /&gt;DBG&amp;gt; set rad hex&lt;BR /&gt;DBG&amp;gt; ex/octaw @@fp:(@@fp)+70&lt;BR /&gt;0000000000664BB0:       000003490066E000 0066E00000000013&lt;BR /&gt;0000000000664BC0:       7FFF800000676000 0066E00000000003&lt;BR /&gt;0000000000664BD0:       0FFFFFFFF00000000 000000000066DE20&lt;BR /&gt;0000000000664BE0:       0000000000000016 0000000100000000&lt;BR /&gt;0000000000664BF0:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C00:       0000000000000000 0000000000000000&lt;BR /&gt;0000000000664C10:       0000000000000000 000000000066DE10&lt;BR /&gt;0000000000664C20:       006675A000664D10 006675F000000000&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;fwiw,&lt;BR /&gt;Hein.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sat, 16 Feb 2008 02:47:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/help-different-open-extended-modes/m-p/4145675#M39324</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2008-02-16T02:47:30Z</dc:date>
    </item>
  </channel>
</rss>

