[Gambas-user] [CRASH REPORT] gbUDisk2
Tony Morehen
tmorehen at ...3602...
Sun Aug 6 17:56:27 CEST 2017
Hello all,
Damn, my program crashed Gambas this way :
1) Run the program
2) Plug in a usb drive
3) Click the mount button, mounts OK
4) Click the unmount button
Program crashes Aborted(6)
Console shows realloc error invalid old size
Background:
I'm writing a Udisks2 module that communicates with UDisks2 over dbus.
It gathers drive info on existing drives and receives notifications when
a new drive is plugged in, usb stick etc.
Two problems:
1) The crash above. Note that unmount works if the usb drive is already
plugged in. Careful: the program defaults to unmounting /dev/sdb1.
Make sure you use the right drive id.
2) The program intially sends some basic drive info to debug output.
First, it prints the info item by item with no problems. Then it tries
to print the same items in one print statement. Some of the output is
garbage. What's worst, I've tried saving each info item to separate
variables. If I step through the assignments one item at a time, the
individual assignment is at first correct. However, after the next item
is assigned, the previous item's value also changes. This looks like a
buffer overrun or a stack overflow.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gbUDisk2-0.0.1-crash-170806-114746.tar.bz2
Type: application/x-bzip
Size: 16423 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20170806/85c0a17b/attachment.bin>
More information about the User
mailing list