# HG changeset patch # User Jim Blandy # Date 738338514 0 # Node ID 905f9fda79b8b249fee1a06cc8891e13df31904d # Parent a655e32e62701fbcb1dd9fc32f8f9695f69c665e * dispextern.h (struct face): New field - `copy', to help us with resource allocation. * xfaces.c (free_frame_faces): Do free the first two faces; don't free anything from a face that's a copy. (intern_frame_face): Mark every face we intern as a copy; its resources are actually a combination of the real faces. (Fset_face_attribute_internal): No need to check if we're trying to free one of the frame's GC's; they never enter into the picture. diff -r a655e32e6270 -r 905f9fda79b8 src/dispextern.h --- a/src/dispextern.h Tue May 25 13:22:21 1993 +0000 +++ b/src/dispextern.h Tue May 25 14:01:54 1993 +0000 @@ -54,6 +54,15 @@ /* Whether or not to underline text in this face. */ char underline; + + /* Does this face own its resources? (color, font, etcetera) + If this is a face which we computed by combining other faces, + then this is true, and we shouldn't free any of the resources + it refers to; the faces from which it was constructed own it. + On the other hand, if this is a face the user created and + filled in directly, then this is false, and we should free the + resources when we free it. */ + char copy; }; /* Let's stop using this and get rid of it. */