[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Python packages hardcoding errno values



Hi.

only symbolic names should be used in programs
because hurd-i386 is the only platform on which these kinds of bugs can manifest themselves in practice.

There are differences also between Linux and FreeBSD
and even between CPUs on Linux, i.e. i386/hppa.

They have common only range 1-34, with the exception of EAGAIN/EDEADLK/EWOULDBLOCK.

On GNU/kFreeBSD are therefore affected at least packages bellow.


Petr


debdelta_0.39trl_i386/usr/bin/debdelta:3457:    if s.errno == 11 :
gdebi-kde_0.6.2_all/usr/share/pyshared/GDebi/KDEAptDialogs.py:97:                if e.errno == 11:
linux/i386:
#define EAGAIN          11      /* Try again */
#define EDEADLK         35      /* Resource deadlock would occur */
#define EWOULDBLOCK     EAGAIN  /* Operation would block */

linux/hppa:
#define EAGAIN          11      /* Try again */
#define EDEADLK         45      /* Resource deadlock would occur */
#define EWOULDBLOCK     246

FreeBSD:
#define EDEADLK         11              /* Resource deadlock avoided */
#define EAGAIN          35              /* Resource temporarily unavailable */
#define EWOULDBLOCK     EAGAIN          /* Operation would block */



python-ldtp_2.0.6-1_all/usr/share/pyshared/ldtp/client.py:78: if (e.errno == 111 or e.errno == 146) and 'localhost' in host:

linux/i386: #define ECONNREFUSED    111     /* Connection refused */
linux/hppa: #define ECONNREFUSED    239     /* Connection refused */
FreeBSD: #define ECONNREFUSED    61              /* Connection refused */


fckeditor_1:2.6.6-1_all/usr/share/fckeditor/editor/filemanager/connectors/py/fckcommands.py:106: elif e.errno==36 or e.errno==2 or e.errno==22: # filename too long / no such file / invalid name

linux/i386: #define ENAMETOOLONG    36      /* File name too long */
linux/hppa: #define ENAMETOOLONG    248     /* File name too long */
FreeBSD: #define ENAMETOOLONG    63              /* File name too long */


Reply to: