[Gambas-user] [Gambas Bug Tracker] Bug #968: Issues found in current build logs for gambas3 on Debian for c_crypt.c and c_window.c

bugtracker at ...3416... bugtracker at ...3416...
Fri Jul 22 22:21:58 CEST 2016


http://gambaswiki.org/bugtracker/edit?object=BUG.968&from=L21haW4-

gbWilly GAMBOS reported a new bug.

Summary
-------

Issues found in current build logs for gambas3 on Debian for c_crypt.c and c_window.c

Type             : Bug
Priority         : Low
Gambas version   : Unknown
Product          : Unknown


Description
-----------

Hi all,

Does any of the devs ever check https://qa.debian.org/bls/packages/g/gambas3.html.

It seems that some of the Gambas 3.8.4 .c files have some issues.

First there is 2 issues in c_crypt.c

c_crypt.c:122 -> pointer trouble at implicit
---------
description:
The build log contains the term
warning: ... makes pointer from integer without a cast

or a

warning: cast to pointer from integer of different size

for the same line as a

warning: implicit declaration of function

There is a extremly high likelihood that this causes misheaviour, at least on 64 bit architectures.

Implicit declaration means a function is used without being declared, which means C assumes all it's arguments are 32 bit integers and the return value is a 32 bit integer. If the return value is a pointer that means it is cast to an integer and back, discarding all the high bits, corrupting pointers.
---------
c_crypt.c:137 --> pointer from integer
---------
The build log contains the term

warning: ... makes pointer from integer without a cast

This usually indicates some problem in the code or some very sloppy programing. There is some high likelyhood this code might also have issues at least on 64 bit architectures.

Using an explicit cast in the code, this compiler warning can be silenced.

If this compiler warning is emitted for the same line as a previous implicit declaration warning, the tag E-pointer-trouble-at-implicit is generated instead. 
---------

Next one issue in c_window.c

c_window.c:563 --> implicit-declaration
---------
The build log contains the term

warning: implicit declaration of function ...

Implicit declaration means a function is used without being declared, which means C knows nothing about the number of arguments, types of arguments or type of the return value.

This is dangerous as it might hide issues the compiler could otherwise warn about or cause bad code. If this is found together with other warnings indicating especially bad things happening, the tag E-pointer-trouble-at-implicit is generated instead. 
---------

Maybe these can prevented easily, so future builds on Debian will no longer have these issues.

Thanks,

gbWilly


System information
------------------

Multiple systems:

1. ---------------------------------------------

[System]
Gambas=3.5.4
OperatingSystem=Linux
Kernel=3.16.0-4-586
Architecture=x86
Distribution=debian 8.1
Desktop=LXDE
Theme=QWindows
Language=en_US.UTF-8
Memory=945M
[Libraries]
Cairo=libcairo.so.2.11400.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.8.12
GStreamer=libgstreamer-1.0.so.0.404.0
GTK+=libgtk-x11-2.0.so.0.2400.25
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.46.0.0
Qt4=libQtCore.so.4.8.6
SDL=libSDL-1.2.so.0.11.4

2. ---------------------------------------------

[System]
Gambas=3.6.2
OperatingSystem=Linux
Kernel=3.16.0-4-586
Architecture=x86
Distribution=debian 8.1
Desktop=LXDE
Theme=QWindows
Language=en_US.UTF-8
Memory=945M
[Libraries]
Cairo=libcairo.so.2.11400.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.8.12
GStreamer=libgstreamer-1.0.so.0.404.0
GTK+3=libgtk-3.so.0.1400.5
GTK+=libgtk-x11-2.0.so.0.2400.25
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.46.0.0
Qt4=libQtCore.so.4.8.6
SDL=libSDL-1.2.so.0.11.4

3. ---------------------------------------------

[System]
Gambas=3.7.1
OperatingSystem=Linux
Kernel=3.16.0-4-586
Architecture=x86
Distribution=debian 8.1
Desktop=LXDE
Theme=QWindows
Language=en_US.UTF-8
Memory=945M
[Libraries]
Cairo=libcairo.so.2.11400.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.8.12
GStreamer=libgstreamer-1.0.so.0.404.0
GTK+3=libgtk-3.so.0.1400.5
GTK+=libgtk-x11-2.0.so.0.2400.25
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.46.0.0
Qt4=libQtCore.so.4.8.6
SDL=libSDL-1.2.so.0.11.4

4. ---------------------------------------------

[System]
Gambas=3.8.90 (rev#7527)
OperatingSystem=Linux
Kernel=3.19.0-28-generic
Architecture=x86
Distribution=Ubuntu 14.04.3 LTS
Desktop=LXDE
Theme=Gtk
Language=en_US.UTF-8
Memory=937M

[Libraries]
Cairo=libcairo.so.2.11301.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.7.6
GStreamer=libgstreamer-0.10.so.0.30.0
GStreamer=libgstreamer-1.0.so.0.204.0
GTK+2=libgtk-x11-2.0.so.0.2400.23
GTK+3=libgtk-3.so.0.1000.8
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.44.0.0
QT4=libQtCore.so.4.8.6
SDL=libSDL-1.2.so.0.11.4

[Environment]
CLUTTER_IM_MODULE=xim
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-d2tYwNrIPc
DEFAULTS_PATH=/usr/share/gconf/Lubuntu.default.path
DESKTOP_SESSION=Lubuntu
DISPLAY=:0
GB_GUI=gb.qt4
GDMSESSION=Lubuntu
GDM_LANG=en_US
GNOME_KEYRING_CONTROL=/run/user/1000/keyring-Eo5i6s
GNOME_KEYRING_PID=1473
GPG_AGENT_INFO=/run/user/1000/keyring-Eo5i6s/gpg:0:1
GTK_IM_MODULE=xim
HOME=<home>
IM_CONFIG_PHASE=1
INSTANCE=
JOB=dbus
LANG=en_US.UTF-8
LANGUAGE=en_US
LC_ADDRESS=nl_NL.UTF-8
LC_IDENTIFICATION=nl_NL.UTF-8
LC_MEASUREMENT=nl_NL.UTF-8
LC_MONETARY=nl_NL.UTF-8
LC_NAME=nl_NL.UTF-8
LC_NUMERIC=nl_NL.UTF-8
LC_PAPER=nl_NL.UTF-8
LC_TELEPHONE=nl_NL.UTF-8
LC_TIME=nl_NL.UTF-8
LOGNAME=<user>
MANDATORY_PATH=/usr/share/gconf/Lubuntu.mandatory.path
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
PWD=<home>
QT4_IM_MODULE=xim
QT_IM_MODULE=xim
SAL_USE_VCLPLUGIN=gtk
SELINUX_INIT=YES
SESSION=Lubuntu
SESSIONTYPE=lxsession
SHELL=/bin/bash
SHLVL=0
SSH_AUTH_SOCK=/run/user/1000/keyring-Eo5i6s/ssh
TEXTDOMAIN=im-config
TEXTDOMAINDIR=/usr/share/locale/
TZ=:/etc/localtime
UPSTART_EVENTS=started xsession
UPSTART_INSTANCE=
UPSTART_JOB=lxsession
UPSTART_SESSION=unix:abstract=/com/ubuntu/upstart-session/1000/1329
USER=<user>
XAUTHORITY=<home>/.Xauthority
XDG_CONFIG_DIRS=/etc/xdg/lubuntu:/etc/xdg/xdg-Lubuntu:/usr/share/upstart/xdg:/etc/xdg
XDG_CONFIG_HOME=<home>/.config
XDG_CURRENT_DESKTOP=LXDE
XDG_DATA_DIRS=/etc/xdg/lubuntu:/usr/local/share:/usr/share:/usr/share/gdm:/var/lib/menu-xdg:/usr/share/Lubuntu:/usr/local/share/:/usr/share/
XDG_GREETER_DATA_DIR=/var/lib/lightdm-data/<user>
XDG_MENU_PREFIX=lxde-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT=seat0
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_ID=c2
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session0
XDG_VTNR=7
XMODIFIERS=@...3498...=ibus
_LXSESSION_PID=1515

5. ---------------------------------------------

[System]
Gambas=3.8.90 (rev#7618)
OperatingSystem=Linux
Kernel=3.2.0-92-generic
Architecture=x86
Distribution=Linux Mint 13 Maya
Desktop=MATE
Theme=Gtk
Language=nl_NL.UTF-8
Memory=2004M

[Libraries]
Cairo=libcairo.so.2.11000.2
Curl=libcurl.so.4.2.0
DBus=libdbus-1.so.3.5.8
GStreamer=libgstreamer-0.10.so.0.30.0
GStreamer=libgstreamer-1.0.so.0.1.0
GTK+2=libgtk-x11-2.0.so.0.2400.10
GTK+3=libgtk-3.so.0.400.2
Poppler=libpoppler.so.19.0.0
QT4=libQtCore.so.4.8.1
SDL=libSDL-1.2.so.0.11.3

[Environment]
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-0u5IGaGXG3,guid=4d001ab8066e9b5d7e5e1f9300000021
DBUS_STARTER_ADDRESS=unix:abstract=/tmp/dbus-0u5IGaGXG3,guid=4d001ab8066e9b5d7e5e1f9300000021
DBUS_STARTER_BUS_TYPE=session
DEFAULTS_PATH=/usr/share/gconf/mate.default.path
DESKTOP_SESSION=mate
DISPLAY=:0
GB_GUI=gb.qt4
GDMSESSION=mate
GDM_XSERVER_LOCATION=local
GPG_AGENT_INFO=/tmp/keyring-956Xzu/gpg:0:1
HOME=<home>
LANG=nl_NL.UTF-8
LC_ADDRESS=nl_NL.UTF-8
LC_IDENTIFICATION=nl_NL.UTF-8
LC_MEASUREMENT=nl_NL.UTF-8
LC_MONETARY=nl_NL.UTF-8
LC_NAME=nl_NL.UTF-8
LC_NUMERIC=nl_NL.UTF-8
LC_PAPER=nl_NL.UTF-8
LC_TELEPHONE=nl_NL.UTF-8
LC_TIME=nl_NL.UTF-8
LOGNAME=<user>
MANDATORY_PATH=/usr/share/gconf/mate.mandatory.path
MATE_DESKTOP_SESSION_ID=this-is-deprecated
MATE_KEYRING_CONTROL=/tmp/keyring-956Xzu
MDMSESSION=mate
MDM_LANG=nl_NL.UTF-8
MDM_XSERVER_LOCATION=local
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
PWD=<home>
SESSION_MANAGER=local/<hostname>:@/tmp/.ICE-unix/1741,unix/<hostname>:/tmp/.ICE-unix/1741
SHELL=/bin/bash
SSH_AGENT_PID=1802
SSH_AUTH_SOCK=/tmp/keyring-956Xzu/ssh
TZ=:/etc/localtime
USER=<user>
USERNAME=<user>
WINDOWPATH=8
XAUTHORITY=<home>/.Xauthority
XDG_CONFIG_DIRS=/etc/xdg/xdg-mate:/etc/xdg
XDG_DATA_DIRS=/usr/share/mate:/usr/local/share/:/usr/share/:/usr/share/mdm/
XDG_SESSION_COOKIE=e227274bb17bcf421ba09f9c00000009-1449781858.809691-713854121






More information about the User mailing list