GNOME Bugzilla – Bug 478318
gdmthemetester : eval: 1: Syntax error: "(" unexpected
Last modified: 2007-09-21 23:41:17 UTC
Please describe the problem: stemp@caderousse:~/gdm$ gdmthemetester xdmcp Blubuntu-List GDM Theme Tester Be sure to test all the environments: console, console-timed, flexi, remote-flexi, xdmcp Also be sure to test using caps lock eval: 1: Syntax error: "(" unexpected /usr/bin/gdmthemetester (line 94 to 99) : if [ "x$XNESTSIZE" = x ] ; then eval `gdmXnest -b` else eval `gdmXnest -b -o "-geometry $XNESTSIZE"` fi Steps to reproduce: 1. gdmthemetester xdmcp Blubuntu-List 2. 3. Actual results: eval: 1: Syntax error: "(" unexpected Expected results: launch the gdm login test Does this happen every time? yes Other information: /usr/bin/gdmthemetester (line 94 to 99) : if [ "x$XNESTSIZE" = x ] ; then eval `gdmXnest -b` else eval `gdmXnest -b -o "-geometry $XNESTSIZE"` fi
*** Bug 478322 has been marked as a duplicate of this bug. ***
It isn't clear to me what the problem is here. I don't see any unexpected "(" characters or other invalid things in the eval lines you highlight. Could you explain how the eval should be constructed so it works on your system. This might be an OS specific problem, since eval depends on how /bin/sh works on your system. Does it work with other themes, or does it just fail with the theme you are testing with?
System : Ubuntu Gutsy - 2.6.22-11-generic It fail with all themes, in fact I don't even thinks it's important : $ gdmthemetester xdmcp foo give me the same error. The problem seems to be the ` character. Maybe a LOCALE problem, and so not related to gdmthemetester.
In a shell script, when you have a command surrounded by ` characters, this simply means to run the command. The eval command causes the program the follows the eval to be run. Whatever output it generates will get executed. Can you tell me which command of the following two gets executed? You could add some "echo" calls to the command to figure this out: if [ "x$XNESTSIZE" = x ] ; then echo "command 1" eval `gdmXnest -b` else echo "command 2 $XNESTSIZE" eval `gdmXnest -b -o "-geometry $XNESTSIZE"` fi Then you will know which command is being executed and what XNESTSIZE is set to if you are using "command 2". Once you know this, try running the gdmXnest command If you are using case 1, run this command: gdmXnest -b If you are using case 2, runt his command: gdmXnest -b -o "-geometry (whatever value is returned for $XNESTSIZE)" And let me know what you see echoed back to the terminal. I'm guessing the eval is failing because the gdmXnest command isn't working as expected.
Here is the result : stemp@caderousse:~/gdm$ gdmXnest -b -o "-geometry 1024x768" ** (gdmXnest:3134): DEBUG: Sending command: 'VERSION' ** (gdmXnest:3134): DEBUG: Got response: 'GDM 2.20.0' ** (gdmXnest:3134): DEBUG: Sending command: 'GET_CONFIG xdmcp/Enable :0.0' ** (gdmXnest:3134): DEBUG: Got response: 'OK true' ** (gdmXnest:3134): DEBUG: Sending command: 'GET_CONFIG xdmcp/HonorIndirect :0.0' ** (gdmXnest:3134): DEBUG: Got response: 'OK true' ** (gdmXnest:3134): DEBUG: Sending command: 'GET_CONFIG daemon/Xnest :0.0' ** (gdmXnest:3134): DEBUG: Got response: 'OK /usr/share/gdm/gdmXnestWrapper -br -audit 0' ** (gdmXnest:3134): DEBUG: Sending command: 'CLOSE' DISPLAY=:20 stemp@caderousse:~/gdm$
It looks like you have debug turned on, which is causing the debug statements (including the offending "(" character) to appear in the output. Does it work better if you turn off debug? Try running gdmsetup and make sure "enable debug messages" is not checked on the security tab. You really shouldn't run GDM with debug turned on since it will cause your syslog to get a lot of unnecessary messages and waste your disk space. If you don't have debug turned on, then the problem perhaps is that GDM has a bug and is turning on debug for the gdmXnest command even when it isn't on?
The debug option is off in gdmsetup. And noting in dmesg or /var/log/syslog or messages. except : stemp@caderousse:/var/log$ cat syslog | grep gdm Sep 19 11:18:08 localhost gdm[5372]: WARNING: bind: Adresse déjà utilisée Sep 19 11:18:08 localhost gdm[5372]: WARNING: bind: Adresse déjà utilisée Sep 19 11:18:08 localhost gdm[5372]: WARNING: Could not create socket! but it was this morning
Yes, there seems to be a bug with gdmXnest that causes it to print debug messages even when debug is not enabled in the configuration file. This should be fixed, then the problem reported would go away.
Great news, thanks a lot for your help.
Created attachment 95996 [details] [review] patch to fix the problem.
I think this patch, which is now upstream and in the 2.20 branch, should fix your problem. If you could test and verify, that would be great. Basically, just needed to turn off debugging in gdmXnestchooser. I noticed gdmsetup had the same problem, so the patch also fixes that.