<?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 Hi Vautier, in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138936#M136617</link>
    <description>&lt;P&gt;Hi Vautier,&lt;/P&gt;&lt;P&gt;Thank you for your help.&lt;BR /&gt;I understand what you are answering but I don't know how to fix this because I am not be good at C programming enough.&lt;BR /&gt;Additionally I have one more question to fix my problem.&lt;BR /&gt;&lt;BR /&gt;The rest of C code is below:&lt;BR /&gt;urlopen(int *ret, char* url)&lt;BR /&gt;{&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; char *prul;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("%s \n", url);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; purl = _fcdtocp(url);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; handle = url_fopen(purl, "r");&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;In the case that url is "http://some_url &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #7777END", url_fopen process does not successed.&lt;BR /&gt;Please let me know how to modify this purl or url string?&lt;BR /&gt;ex1) purl = _fcdtocp(url(0:nlength-2))&lt;BR /&gt;ex2) CHARACTER&amp;nbsp; URL(0:128)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; URL="http://***.**.***.**/url/something.php?inf=some&amp;amp;tm=200001011200"&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; URL(0)=" "&lt;BR /&gt;ex3) or something&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thank you,&lt;BR /&gt;Kihang&lt;/P&gt;</description>
    <pubDate>Tue, 10 Mar 2020 08:50:00 GMT</pubDate>
    <dc:creator>youn__kihang</dc:creator>
    <dc:date>2020-03-10T08:50:00Z</dc:date>
    <item>
      <title>How to transport character variable from Fortran to C without transiton</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138934#M136615</link>
      <description>&lt;P&gt;Hello developers,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have some question related transporting chracter variable from Fortran to C.&lt;BR /&gt;Here are my codes:&lt;/P&gt;&lt;P&gt;# In Fortran&lt;BR /&gt;CHARACTER URL*128&lt;BR /&gt;URL='http://***.**.***.**/url/something.php?inf=some&amp;amp;tm=200001011200'&lt;BR /&gt;WRITE(URL(49:59),'(A10)') YYYYMMDDHH&lt;BR /&gt;CALL URLOPEN(IU, URL)&lt;/P&gt;&lt;P&gt;# In C&lt;BR /&gt;urlopen(int *ret, char* url) {&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;printf("%s \n", url);}&lt;/P&gt;&lt;P&gt;&amp;nbsp;# Result&lt;BR /&gt;'http://***.**.***.**/url/somethine.php?inf=some&amp;amp;tm=200001011200'&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #7777END&lt;/P&gt;&lt;P&gt;One odd thing is that it is okay in character length under 128(127,126,..).&lt;BR /&gt;Is there any problem to think about in the current situation? Is there a problem if the char length in C exceeds 128?&lt;BR /&gt;Please let me know if there is the way to use a longer length character because the length of URL may increase.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Mar 2020 08:07:10 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138934#M136615</guid>
      <dc:creator>youn__kihang</dc:creator>
      <dc:date>2020-03-10T08:07:10Z</dc:date>
    </item>
    <item>
      <title>C strings are null terminated</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138935#M136616</link>
      <description>&lt;P&gt;C strings are null terminated, so add a char(0) at the end of your fortran string.&lt;/P&gt;&lt;P&gt;There is no limit for C string length.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Mar 2020 08:27:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138935#M136616</guid>
      <dc:creator>GVautier</dc:creator>
      <dc:date>2020-03-10T08:27:00Z</dc:date>
    </item>
    <item>
      <title>Hi Vautier,</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138936#M136617</link>
      <description>&lt;P&gt;Hi Vautier,&lt;/P&gt;&lt;P&gt;Thank you for your help.&lt;BR /&gt;I understand what you are answering but I don't know how to fix this because I am not be good at C programming enough.&lt;BR /&gt;Additionally I have one more question to fix my problem.&lt;BR /&gt;&lt;BR /&gt;The rest of C code is below:&lt;BR /&gt;urlopen(int *ret, char* url)&lt;BR /&gt;{&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; char *prul;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("%s \n", url);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; purl = _fcdtocp(url);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; handle = url_fopen(purl, "r");&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;In the case that url is "http://some_url &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #7777END", url_fopen process does not successed.&lt;BR /&gt;Please let me know how to modify this purl or url string?&lt;BR /&gt;ex1) purl = _fcdtocp(url(0:nlength-2))&lt;BR /&gt;ex2) CHARACTER&amp;nbsp; URL(0:128)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; URL="http://***.**.***.**/url/something.php?inf=some&amp;amp;tm=200001011200"&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; URL(0)=" "&lt;BR /&gt;ex3) or something&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thank you,&lt;BR /&gt;Kihang&lt;/P&gt;</description>
      <pubDate>Tue, 10 Mar 2020 08:50:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138936#M136617</guid>
      <dc:creator>youn__kihang</dc:creator>
      <dc:date>2020-03-10T08:50:00Z</dc:date>
    </item>
    <item>
      <title>In the fortran code, add /</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138937#M136618</link>
      <description>&lt;P&gt;In the fortran code, add //char(0) at the end of the url= statement.&lt;/P&gt;&lt;P&gt;Nothing to do on C side.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Mar 2020 09:14:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/How-to-transport-character-variable-from-Fortran-to-C-without/m-p/1138937#M136618</guid>
      <dc:creator>GVautier</dc:creator>
      <dc:date>2020-03-10T09:14:26Z</dc:date>
    </item>
  </channel>
</rss>

