1 |
/* Managing sub-stores |
/* Managing sub-stores |
2 |
|
|
3 |
Copyright (C) 1995, 1996, 1997, 2001 Free Software Foundation, Inc. |
Copyright (C) 1995,96,97,2001,02 Free Software Foundation, Inc. |
4 |
Written by Miles Bader <miles@gnu.ai.mit.edu> |
Written by Miles Bader <miles@gnu.org> |
5 |
|
|
6 |
This file is part of the GNU Hurd. |
This file is part of the GNU Hurd. |
7 |
|
|
8 |
The GNU Hurd is free software; you can redistribute it and/or |
The GNU Hurd is free software; you can redistribute it and/or |
29 |
/* Set STORE's current children list to (a copy of) CHILDREN and NUM_CHILDREN. */ |
/* Set STORE's current children list to (a copy of) CHILDREN and NUM_CHILDREN. */ |
30 |
error_t |
error_t |
31 |
store_set_children (struct store *store, |
store_set_children (struct store *store, |
32 |
struct store *const *children, unsigned num_children) |
struct store *const *children, size_t num_children) |
33 |
{ |
{ |
34 |
unsigned size = num_children * sizeof (struct store_run); |
unsigned size = num_children * sizeof (struct store_run); |
35 |
struct store **copy = malloc (size); |
struct store **copy = malloc (size); |
175 |
{ |
{ |
176 |
const char *pfx_end = name; |
const char *pfx_end = name; |
177 |
|
|
178 |
while (isalnum (pfx_end)) |
while (isalnum (*pfx_end)) |
179 |
pfx_end++; |
pfx_end++; |
180 |
|
|
181 |
if (*pfx_end++ != ':') |
if (*pfx_end++ != ':') |