comparison src/editfns.c @ 16648:912ff9d36bb1

(Fuser_full_name): Use build_string instead of make_string.
author Richard M. Stallman <rms@gnu.org>
date Mon, 09 Dec 1996 02:41:44 +0000
parents 2103a88cc61f
children 6802dbd07a80
comparison
equal deleted inserted replaced
16647:fa79e7cb58d4 16648:912ff9d36bb1
1 /* Lisp functions pertaining to editing. 1 /* Lisp functions pertaining to editing.
2 Copyright (C) 1985,86,87,89,93,94,95 Free Software Foundation, Inc. 2 Copyright (C) 1985,86,87,89,93,94,95,96 Free Software Foundation, Inc.
3 3
4 This file is part of GNU Emacs. 4 This file is part of GNU Emacs.
5 5
6 GNU Emacs is free software; you can redistribute it and/or modify 6 GNU Emacs is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by 7 it under the terms of the GNU General Public License as published by
583 pw = (struct passwd *) getpwnam (XSTRING (uid)->data); 583 pw = (struct passwd *) getpwnam (XSTRING (uid)->data);
584 else 584 else
585 error ("Invalid UID specification"); 585 error ("Invalid UID specification");
586 586
587 if (!pw) 587 if (!pw)
588 return make_string ("unknown"); 588 return build_string ("unknown");
589 589
590 p = (unsigned char *) USER_FULL_NAME; 590 p = (unsigned char *) USER_FULL_NAME;
591 /* Chop off everything after the first comma. */ 591 /* Chop off everything after the first comma. */
592 q = (unsigned char *) index (p, ','); 592 q = (unsigned char *) index (p, ',');
593 full = make_string (p, q ? q - p : strlen (p)); 593 full = make_string (p, q ? q - p : strlen (p));