How to Use the Citrix Client on Fedora Core 3
When I first tried to start up the Citrix ICA client on Fedora Core 3, it crashed. Hard. But it wasn't your ordinary segfault, it was something I hadn't seen before:
*** glibc detected *** double free or corruption: 0x0937d008 ***After several false starts, including a pathetic attempt to understand the Citrix Program Neighborhood, I Googled the error message, and found a bit in the FC 3 Release Notes:
Should you have a program from a third party ISV that triggers these corruption checks and displays a message, you should file a defect report with the application's vendor, since this indicates a serious bug.Very ominous. And since the ICA client is proprietary software with a very slow release cycle, I had very little confidence that this "serious bug" would be fixed anytime soon.
The crash was caused by some sanity checking done by this version of glibc, in order to prevent buffer overflows and other memory corruption nasties, so at first it seemed almost counterproductive to turn off the sanity checking. Indeed, when I tried the first option (MALLOC_CHECK_=0, or "no error message, no kill"), it simply segfaulted. On a lark, though, I tried the second option(MALLOC_CHECK_=1, "error message, no kill"), and it seemed to work. I have no idea why.
Unfortunately, this makes it difficult to use the ICA client browser plugin, which is used to launch Citrix connections from a web-based login page. For it to work, you have to pass MALLOC_CHECK_=1 to the browser so the plugin will see the environment variable. So instead, I decided to wrap the command-line client in a shell script, and use it to "open" Citirx connection files (MIME type application/x-ica) in the browser. Here's the shell script:
#!/bin/bash
MALLOC_CHECK_=1 /usr/lib/ICAClient/wfica.sh -file $1