Lines Matching +full:3 +full:g
2 * SPDX-License-Identifier: BSD-3-Clause
18 * 3. Neither the name of the University nor the names of its contributors
64 static FILE usual[FOPEN_MAX - 3];
65 static struct glue uglue = { NULL, FOPEN_MAX - 3, usual };
67 static FILE __sF[3] = {
77 struct glue __sglue = { &uglue, 3, __sF };
93 struct glue *g; in moreglue() local
99 g = (struct glue *)malloc(sizeof(*g) + align + n * sizeof(FILE)); in moreglue()
100 if (g == NULL) in moreglue()
102 p = (FILE *)roundup((uintptr_t)(g + 1), align); in moreglue()
103 g->next = NULL; in moreglue()
104 g->niobs = n; in moreglue()
105 g->iobs = p; in moreglue()
108 return (g); in moreglue()
119 struct glue *g; in __sfp() local
127 for (g = &__sglue; g != NULL; g = g->next) { in __sfp()
128 for (fp = g->iobs, n = g->niobs; --n >= 0; fp++) in __sfp()
133 if ((g = moreglue(NDYNAMIC)) == NULL) in __sfp()
136 SET_GLUE_PTR(lastglue->next, g); /* atomically append glue to list */ in __sfp()
137 lastglue = g; /* not atomic; only accessed when locked */ in __sfp()
138 fp = g->iobs; in __sfp()
172 struct glue *g; in f_prealloc() local
181 for (g = &__sglue; (n -= g->niobs) > 0 && g->next; g = g->next) in f_prealloc()
183 if ((n > 0) && ((g = moreglue(n)) != NULL)) { in f_prealloc()
185 SET_GLUE_PTR(lastglue->next, g); in f_prealloc()
186 lastglue = g; in f_prealloc()