Author nobody
Recipients
Date 2000-07-31.20:00:54
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Jitterbug-Id%3
a 102
Submitted-By: "=?iso-8859-2?B?VmxhZGlt7XIgQmVuZbk=?=%2
2 <Vladimir.Benes@pvt.cz>
Date: Mon, 11 Oct 1999 13:00:07 +0200%
0aVersion: None
OS: None

Good afternoon,

    I have found a bug 
on Python 1.5.2. This bug doesn't occur on Python
1.5.1.

Python version
s and OS:
- Python 1.5.1. at Debian GNU/Linux 2.0.36
- Python 1.5.2. at De
bian GNU/Linux 2.2.9

Bug: Incorrect signal processing (Python 1.5.2).

    Process can assign procedure for signal processing. When process is
wai
ting at system call and this signal occur, then the signal assigned
procedure 
is otherwise correctly completed but then waiting at system call
is broken and
 process continues.

    Here is a simple program for demonstrate this bug:

#!/usr/bin/python
import signal
import sys

def signal_handle
(signum, frame) :
  signal.signal(signal.SIGALRM, signal_handle)
 
 signal.alarm(2)
  print "signal"

signal_handle(0,0)
a=sys.stdin.readline()
print "Line examined..."
b=sys.stdin.readline%2
8)
print "Line examined..."
print a,b,"end"
# end of example

    Correct behaviour: Message "Line examined..." occurs only after pr
essing
ENTER by user.
    Bug: Message "Line examined..." occurs immed
iately after signal occured
and procedure signal_handle finished. Output then look thus (when no input
entered):

signal
signal
Line examined.
..
signal
Line examined...
  end

    This bug appears at any signal o
ccur and whatever process waiting at
system call. Some system call even produces exception (e.g. waiting for data
or connection on socket).

    Bug
 is perhaps caused by wrong seting "siginterrupt" on module signal. I
have
n't found any way how call in Python program "siginterrupt" for correct
behavior of signal processing.

        Good bye, V. Benes

****
**************************%2
a**************************%
2a******************
    Ing. Vladimir Benes, pvt.net
    PVT, a.s., OZ Chomutov
    e-mail: vladimir.benes@pvt.cz
, vladimir.benes@sms.paegas.cz
***************
*****************************************************%
2a*******



Audit trail:
Mon Oct 11 18:12:13 1999
	guido	moved from incoming to open

History
Date User Action Args
2007-08-23 13:49:02adminlinkissue210587 messages
2007-08-23 13:49:02admincreate