# HG changeset patch # User Richard M. Stallman # Date 813103206 0 # Node ID 4ce211a90724951f9523347fb7efb31802292b2a # Parent fd14ccddb85a773c288b39171f8102b009b3be52 (describe_vector): Use Flength to get length of vector. diff -r fd14ccddb85a -r 4ce211a90724 src/keymap.c --- a/src/keymap.c Sat Oct 07 21:59:28 1995 +0000 +++ b/src/keymap.c Sat Oct 07 22:00:06 1995 +0000 @@ -2295,6 +2295,7 @@ Lisp_Object suppress; Lisp_Object kludge; int first = 1; + int size; struct gcpro gcpro1, gcpro2, gcpro3; definition = Qnil; @@ -2308,7 +2309,10 @@ if (partial) suppress = intern ("suppress-keymap"); - for (i = 0; i < XVECTOR (vector)->size; i++) + /* This does the right thing for char-tables as well as ordinary vectors. */ + size = XFASTINT (Flength (vector)); + + for (i = 0; i < size; i++) { QUIT; definition = get_keyelt (XVECTOR (vector)->contents[i], 0);