<?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: Coredump in kornshell but not in possix? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467108#M774533</link>
    <description>Just a note about debugging (tracing with set -x): the trace output will go to stderr. So to trace a shell script with all output into a file:&lt;BR /&gt;&lt;BR /&gt;sh -x myscript arg1 arg2 &amp;gt; /var/tmp/tracefile 2&amp;gt;&amp;amp;1&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Sat, 25 Nov 2000 22:20:52 GMT</pubDate>
    <dc:creator>Bill Hassell</dc:creator>
    <dc:date>2000-11-25T22:20:52Z</dc:date>
    <item>
      <title>Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467099#M774524</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I noticed something weird in the kornshell, the attached script will generate a memory fault (SIGSEGV) when executed using /usr/bin/ksh but when the first line is changed to #!/usr/bin/sh it will run without any problems! Does anyone have a clue what's going on? (Seems like a bug to me ...)&lt;BR /&gt;&lt;BR /&gt;Greetz, Danny</description>
      <pubDate>Fri, 24 Nov 2000 11:12:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467099#M774524</guid>
      <dc:creator>Danny Engelbarts</dc:creator>
      <dc:date>2000-11-24T11:12:52Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467100#M774525</link>
      <description>I've just run your script on my 10.20 system without a problem.&lt;BR /&gt;&lt;BR /&gt;What OS do you have ? Patches ?&lt;BR /&gt;&lt;BR /&gt;Can you also supply the stderr output seeing as you included set -x in the script. It would be good to see exactly where the SIGSEGV is occurring.</description>
      <pubDate>Fri, 24 Nov 2000 11:44:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467100#M774525</guid>
      <dc:creator>Dave Kelly_1</dc:creator>
      <dc:date>2000-11-24T11:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467101#M774526</link>
      <description>Hey Dave,&lt;BR /&gt;&lt;BR /&gt;Here's some more info (attachment), although i did include the set  -x there is no debug output?&lt;BR /&gt;I ran the original on a 10.10 system, i've tried on 10.20 as well and i get the same error.&lt;BR /&gt;&lt;BR /&gt;Greetz, Danny.</description>
      <pubDate>Fri, 24 Nov 2000 12:18:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467101#M774526</guid>
      <dc:creator>Danny Engelbarts</dc:creator>
      <dc:date>2000-11-24T12:18:32Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467102#M774527</link>
      <description>don't know why but the problem points to the shift statement within the while getopts ... do ... done loop&lt;BR /&gt;Remove the shift line and add after the loop&lt;BR /&gt;&lt;BR /&gt;shift $(($OPTIND -1))&lt;BR /&gt;&lt;BR /&gt;then the script runs at both shells</description>
      <pubDate>Fri, 24 Nov 2000 12:21:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467102#M774527</guid>
      <dc:creator>Rainer_1</dc:creator>
      <dc:date>2000-11-24T12:21:45Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467103#M774528</link>
      <description>Yep! That's it ... still wondering why now ;o)&lt;BR /&gt;&lt;BR /&gt;Thanks! Danny.</description>
      <pubDate>Fri, 24 Nov 2000 12:40:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467103#M774528</guid>
      <dc:creator>Danny Engelbarts</dc:creator>
      <dc:date>2000-11-24T12:40:45Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467104#M774529</link>
      <description>&lt;BR /&gt;Your problem is you are making too shifts ( more than arguments).&lt;BR /&gt;&lt;BR /&gt;insert echo $# $* before shift and run.&lt;BR /&gt;&lt;BR /&gt;See man getopts:&lt;BR /&gt;&lt;BR /&gt;thera are an example that use shift out of loop and ussing $OPTIND.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HTH</description>
      <pubDate>Fri, 24 Nov 2000 13:01:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467104#M774529</guid>
      <dc:creator>Carlos Fernandez Riera</dc:creator>
      <dc:date>2000-11-24T13:01:37Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467105#M774530</link>
      <description>Hmmm,&lt;BR /&gt;&lt;BR /&gt;If i read the manual correctly getopts should only walk through the "legal options" i.e. all options with either a preceding - or + sign. But it seems the implementation in the kornshell walks through the other options as well?&lt;BR /&gt;&lt;BR /&gt;Danny.</description>
      <pubDate>Fri, 24 Nov 2000 13:31:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467105#M774530</guid>
      <dc:creator>Danny Engelbarts</dc:creator>
      <dc:date>2000-11-24T13:31:40Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467106#M774531</link>
      <description>&lt;BR /&gt;I understand that getopts may search over all args to find all options.&lt;BR /&gt;&lt;BR /&gt;For your script perhaps you will prefer:&lt;BR /&gt;&lt;BR /&gt;DiffTime -h -s time -e time &lt;BR /&gt;&lt;BR /&gt;and getopt hs:e:.&lt;BR /&gt;&lt;BR /&gt;See man 3c getopt too.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 24 Nov 2000 13:49:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467106#M774531</guid>
      <dc:creator>Carlos Fernandez Riera</dc:creator>
      <dc:date>2000-11-24T13:49:22Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467107#M774532</link>
      <description>Hi Danny,&lt;BR /&gt;&lt;BR /&gt;Check with this command "swlist -l fileset|grep sh" to see if you have patch PHKL_19762 installed on your server.&lt;BR /&gt;The patch is a fix for debugging shared lib gets SIGSEGV problem.</description>
      <pubDate>Fri, 24 Nov 2000 15:32:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467107#M774532</guid>
      <dc:creator>CHRIS_ANORUO</dc:creator>
      <dc:date>2000-11-24T15:32:56Z</dc:date>
    </item>
    <item>
      <title>Re: Coredump in kornshell but not in possix?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467108#M774533</link>
      <description>Just a note about debugging (tracing with set -x): the trace output will go to stderr. So to trace a shell script with all output into a file:&lt;BR /&gt;&lt;BR /&gt;sh -x myscript arg1 arg2 &amp;gt; /var/tmp/tracefile 2&amp;gt;&amp;amp;1&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sat, 25 Nov 2000 22:20:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/coredump-in-kornshell-but-not-in-possix/m-p/2467108#M774533</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2000-11-25T22:20:52Z</dc:date>
    </item>
  </channel>
</rss>

