--- rxvt-unicode/src/xdefaults.C 2010/12/18 18:17:39 1.149 +++ rxvt-unicode/src/xdefaults.C 2011/05/30 18:39:04 1.154 @@ -6,7 +6,7 @@ * Copyright (c) 1994 Robert Nation * - original version * Copyright (c) 1997,1998 mj olesen - * Copyright (c) 2003-2006 Marc Lehmann + * Copyright (c) 2003-2006 Marc Lehmann * Copyright (c) 2007 Emanuele Giaquinta * * This program is free software; you can redistribute it and/or modify @@ -399,7 +399,7 @@ case 0: /* brief listing */ rxvt_log (" [-help] [--help]\n"); - for (col = 1, i = 0; i < ARRAY_LENGTH(optList); i++) + for (col = 1, i = 0; i < ecb_array_length (optList); i++) if (optList[i].desc != NULL) { int len = 0; @@ -407,7 +407,7 @@ if (optList[i].arg) len = strlen (optList[i].arg) + 1; assert (optList[i].opt != NULL); - len += 4 + strlen (optList[i].opt) + (optList_isBool (i) ? 2: 0); + len += 4 + strlen (optList[i].opt) + (optList_isBool (i) ? 2 : 0); col += len; if (col > 79) { @@ -427,7 +427,7 @@ case 1: /* full command-line listing */ rxvt_log (" [options] [-e command args]\n\nwhere options include:\n"); - for (i = 0; i < ARRAY_LENGTH(optList); i++) + for (i = 0; i < ecb_array_length (optList); i++) if (optList[i].desc != NULL) { assert (optList[i].opt != NULL); @@ -446,7 +446,7 @@ rxvt_log (" [options] [-e command args]\n\n" "where resources (long-options) include:\n"); - for (i = 0; i < ARRAY_LENGTH(optList); i++) + for (i = 0; i < ecb_array_length (optList); i++) if (optList[i].kw != NULL) rxvt_log (" %s: %*s%s\n", optList[i].kw, @@ -463,7 +463,6 @@ rxvt_log ("\n\n"); rxvt_exit_failure (); - /* NOTREACHED */ } /*}}} */ @@ -510,13 +509,13 @@ rxvt_usage (0); /* feature: always try to match long-options */ - for (entry = 0; entry < ARRAY_LENGTH(optList); entry++) + for (entry = 0; entry < ecb_array_length (optList); entry++) if ((optList[entry].kw && !strcmp (opt, optList[entry].kw)) || (!longopt && optList[entry].opt && !strcmp (opt, optList[entry].opt))) break; - if (entry < ARRAY_LENGTH(optList)) + if (entry < ecb_array_length (optList)) { if (optList_isReverse (entry)) flag = !flag; @@ -524,7 +523,7 @@ if (optList_isString (entry)) { /* - * special cases are handled in main.c:main () to allow + * special cases are handled in init_resources () to allow * X resources to set these values before we settle for * default values */ @@ -587,14 +586,13 @@ * "rxvt" "keysym" "0xFF01" * value will be a string */ -/* ARGSUSED */ int -rxvt_define_key (XrmDatabase *database UNUSED, - XrmBindingList bindings UNUSED, +rxvt_define_key (XrmDatabase *database ecb_unused, + XrmBindingList bindings ecb_unused, XrmQuarkList quarks, - XrmRepresentation *type UNUSED, + XrmRepresentation *type ecb_unused, XrmValue *value, - XPointer closure UNUSED) + XPointer closure ecb_unused) { int last; @@ -667,7 +665,7 @@ { unsigned int i; - for (i=0; i < ARRAY_LENGTH(keysym_vocabulary); ++i) + for (i=0; i < ecb_array_length (keysym_vocabulary); ++i) { if (strncmp (str, keysym_vocabulary [i].name, keysym_vocabulary [i].len) == 0) { @@ -677,7 +675,7 @@ } } - if (i >= ARRAY_LENGTH(keysym_vocabulary)) + if (i >= ecb_array_length (keysym_vocabulary)) return -1; if (*str == '-') @@ -747,7 +745,7 @@ /* * Query resources for options that affect us */ - for (int entry = 0; entry < ARRAY_LENGTH(optList); entry++) + for (int entry = 0; entry < ecb_array_length (optList); entry++) { int s; const char *kw = optList[entry].kw;