~ubuntu-branches/debian/lenny/xiterm+thai/lenny

« back to all changes in this revision

Viewing changes to src/main.c

  • Committer: Bazaar Package Importer
  • Author(s): Neutron Soutmun, thanks Debian security audit team
  • Date: 2008-04-24 16:21:09 UTC
  • mfrom: (0.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20080424162109-sdpcoscuusd8uax3
Tags: 1.09-1
* New upstream release.
  - Fix security risk for X11 connection stealth (CVE-2008-1692)
    [thanks Debian security audit team]
  - Remove build-dependency on Xt Intrinsic
  - Clear much more GCC warnings
  - Improve make rules and some code structure
  - Thai-specific info in man page
  - Really enable Xpm support when available.
  - Less memory usage at load time, by removing unused linkages to libSM
    and libICE.
  - New desktop icon. [Neutron Soutmun]
* debian/control: 
  - Add build-dep on pkg-config to satisfy the upstream changes.
  - Drop build-dep on libxt-dev as upstream changes.
* debian/rules, debian/xiterm+xiterm-icon.uuencode: 
  - Drop the binary to text icon file and related installation, 
    the icon file included in the current upstream source.
  - Drop the workaround, rename manpage before the installation. 
    The upstream renamed the manpage from xiterm.1 to xiterm+thai.1.
* debian/watch: Fix the typo upstream release ftp link.
* lintian clean:
  - debian/txiterm.1: Fix the mistaken hyphen-used-as-minus-sign. 
  - debian/xiterm+thai.desktop: Fix the desktop-entry-contains-encoding-key
    by drop the Encoding key which it is now deprecated.
* debian/txiterm, debian/xiterm+thai.desktop: 
  - Add the parameters to set the white foreground and black background color
    to the caller which can turn more readable screen.

Show diffs side-by-side

added added

removed removed

Lines of Context:
279
279
scale_pixmap (const char *geom)
280
280
{
281
281
  static char str[] = "[1000x1000+100+100]";    /* should be big enough */
282
 
  int w = 0, h = 0, x = 0, y = 0;
 
282
  int x = 0, y = 0;
 
283
  unsigned int w = 0, h = 0;
283
284
  int flags;
284
285
  int changed = 0;
285
286
 
928
929
#ifdef XPM_BACKGROUND
929
930
  if (rs_backgroundPixmap != NULL)
930
931
    {
931
 
      char *p = rs_backgroundPixmap;
 
932
      const char *p = rs_backgroundPixmap;
932
933
      if ((p = strchr (p, ';')) != NULL)
933
934
        {
934
935
          p++;
1228
1229
search_path (const char *pathlist, const char *file, const char *ext)
1229
1230
{
1230
1231
  static char name[256];
1231
 
  char *p, *path;
 
1232
  const char *p, *path;
1232
1233
  int maxpath, len;
1233
1234
 
1234
1235
  if (!access (file, R_OK))
1292
1293
Pixmap
1293
1294
set_bgPixmap (const char *file)
1294
1295
{
1295
 
  char *f;
 
1296
  const char *f;
1296
1297
 
1297
1298
  assert (file != NULL);
1298
1299
 
1319
1320
#endif
1320
1321
          f = search_path (getenv ("PATH"), file, XPM_EXT);
1321
1322
 
1322
 
      if (f == NULL || XpmReadFileToPixmap (Xdisplay, Xroot, f,
 
1323
      if (f == NULL || XpmReadFileToPixmap (Xdisplay, Xroot, (char *)f,
1323
1324
                                            &bgPixmap.pixmap,
1324
1325
                                            NULL, &xpmAttr))
1325
1326
        {
1372
1373
    case XTerm_title:
1373
1374
#ifdef STATIC_TITLE
1374
1375
#ifdef THAI
1375
 
       set_title ("X Terminal International (THAI) 1.06");
 
1376
       set_title ("X Terminal International (THAI) " VERSION);
1376
1377
#else
1377
1378
       set_title ("X Terminal International ���");
1378
1379
#endif
1652
1653
  /*
1653
1654
   * Open display, get options/resources and create the window
1654
1655
   */
1655
 
  if ((display_name = getenv ("DISPLAY")) == NULL)
1656
 
    display_name = ":0";
1657
 
 
1658
1656
  get_options (argc, argv);
1659
1657
 
 
1658
  if (!display_name && (display_name = getenv ("DISPLAY")) == NULL)
 
1659
    {
 
1660
      print_error ("can't open display, DISPLAY is not set?\n");
 
1661
      exit (EXIT_FAILURE);
 
1662
    }
 
1663
 
1660
1664
  Xdisplay = XOpenDisplay (display_name);
1661
1665
  if (!Xdisplay)
1662
1666
    {