Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 99743 - x11-misc/xdialog-2.1.1 infobox returns 0 when timeout expires instead of returning 255
Summary: x11-misc/xdialog-2.1.1 infobox returns 0 when timeout expires instead of retu...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Desktop Misc. Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-20 20:14 UTC by Reid Fleming
Modified: 2005-07-23 18:10 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Reid Fleming 2005-07-20 20:14:45 UTC
the "infobox" widget (?) in Xdialog (versions 2.1.1 and 2.1.2) does not work
correctly.  when given a timeout, it always returns an exit code of 0.  if the
timeout expires it should return 255.  this makes it impossible to tell whether a 
button was pressed or if the timeout expired before a button was pressed.

Reproducible: Always
Steps to Reproduce:
1. copy the following code (taken from the xdialog website) into "test.sh":
#!/bin/bash
Xdialog --title "INFO BOX" --infobox "Hi, this is an information box.\n\
It is different from a message box in that it will not pause waiting\n\
for input after displaying the message.  You have 20 seconds to read this..." 13
45 20000
case $? in
0)
    echo "OK";;
255)
    echo "Box closed.";;
esac
exit 0
2. run the code using "sh test.sh"
3. wait 20 seconds
Actual Results:  
it printed "OK".

Expected Results:  
it should have printed "Box closed."

gentoo universal 2004.3 (up to date), Xdialog 2.1.1
Comment 1 Jonathan Smith (RETIRED) gentoo-dev 2005-07-23 18:08:54 UTC
this doesn't seem to be unique to gentoo

i've emailed the author with a link to this bug
Comment 2 Jonathan Smith (RETIRED) gentoo-dev 2005-07-23 18:10:50 UTC
oh, i know this has nothing to do with your bug, but i version bumped, so that
now 2.1.2 is ~arch'd in portage