|
Post by barryk on Dec 7, 2015 2:13:18 GMT 1
I have a "popup" utility, that displays a message on the screen. It was discussed on this forum a year or so ago.
Anyway, it started to misbehave. It has a timeout feature, that would cause the message to disappear after a certain number of seconds.
This timeout feature stopped working. I have tested with BaCon 3.0.2, and 3.2.1, both have the problem. I am currently running on Ubuntu 15.10 Wily Werewolf 64-bit, so maybe the problem is a recent libc?
Whatever, here is the problem:
terminate$="10" terminate=VAL(terminate$) IF ERROR!=0 THEN terminate=0
VAL() works, but is returning an error code of 3. It should be zero, and indeed used to be zero.
I removed that error test, and now popup works, but it would be better if VAL() is fixed, if you can do that thanks.
Regards, Barry
|
|
|
Post by Pjot on Dec 7, 2015 19:51:18 GMT 1
Hi Barry, I see you're checking the reserved variable ERROR. However, the VAL() function does not put a value into ERROR. This variable ERROR contains the last known runtime error value BaCon has encountered. It can be set to '0' explicitly in your program. If the ERROR variable contains the value '3' it means that BaCon cannot find a library to perform the IMPORT on. So my guess is, that your new Linux installation does not contain the library you're looking for. Most likely, its name has changed (this happens often when installing new Linux releases). HTH Peter
|
|
|
Post by barryk on Dec 8, 2015 0:42:52 GMT 1
Ah, I see, that is unexpected!
I have been coding bash/sh/ash shell scripts for so long, just thinking of an error value returned by (almost) every operation, zero if success. What we expect with C functions also.
Thanks for the feedback. I will try to find out what specifically is causing that "3".
|
|