Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!bloom-beacon.mit.edu!bloom-beacon.mit.edu!panix!not-for-mail From: Grant Edwards Newsgroups: comp.lang.python Subject: Re: os.system error returns Date: Fri, 12 Jun 2015 13:53:03 +0000 (UTC) Organization: PANIX Public Access Internet and UNIX, NYC Lines: 21 Message-ID: References: <2ebdfdf225c075b2f5ef350b06bc14f0@myglnc.com> NNTP-Posting-Host: 67-130-15-94.dia.static.qwest.net Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: reader1.panix.com 1434117183 11449 67.130.15.94 (12 Jun 2015 13:53:03 GMT) X-Complaints-To: abuse@panix.com NNTP-Posting-Date: Fri, 12 Jun 2015 13:53:03 +0000 (UTC) User-Agent: slrn/1.0.2 (Linux) Xref: csiph.com comp.lang.python:92523 On 2015-06-12, Ben Finney wrote: > There is no standardisation of exit status values between different > programs. The best one can say is “exit status 0 means success”. > Anything further is specific to particular programs and is not > universal. > > You'll need to see the documentation for ‘modprobe(1)’ to find out what > its different exit status values mean. It's modprobe(8), and all the man page says is that it returns non-zero if you try to remove or insert a module it can't find. Explicitly checking for an os.system() return value of 1<<8 seems like a pretty bad idea to me, since there's nothing in the modprobe docs that gurantees it will return 1 under some particular conditions. -- Grant Edwards grant.b.edwards Yow! YOU PICKED KARL at MALDEN'S NOSE!! gmail.com