summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>1996-01-17 20:40:29 +0000
committerMiles Bader <miles@gnu.org>1996-01-17 20:40:29 +0000
commit113d7cbaf91aa8697042c28ce6d2ec196a6a7879 (patch)
tree90578af35f9b5cccecfb988bb91762042d85e2c9
parent3bfb1a0f033dbd5998b29fc52e268c57f4e62d20 (diff)
Formerly make.c.~3~
-rw-r--r--libstore/make.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/libstore/make.c b/libstore/make.c
index 7c8ed717..fe951527 100644
--- a/libstore/make.c
+++ b/libstore/make.c
@@ -1,6 +1,6 @@
/* Store allocation/deallocation
- Copyright (C) 1995 Free Software Foundation, Inc.
+ Copyright (C) 1995, 1996 Free Software Foundation, Inc.
Written by Miles Bader <miles@gnu.ai.mit.edu>
@@ -24,18 +24,21 @@
#include "store.h"
-/* Allocate a new store structure of class CLASS, with meths METHS. */
+/* Allocate a new store structure of class CLASS, with meths METHS, and the
+ various other fields initialized to the given parameters. */
struct store *
-_make_store (enum file_storage_class class, struct store_meths *meths)
+_make_store (enum file_storage_class class, struct store_meths *meths,
+ mach_port_t port, size_t block_size,
+ off_t *runs, size_t runs_len)
{
struct store *store = malloc (sizeof (struct store));
if (store)
{
store->name = 0;
- store->port = MACH_PORT_NULL;
+ store->port = port;
store->runs = 0;
store->runs_len = 0;
- store->block_size = 0;
+ store->block_size = block_size;
store->source = MACH_PORT_NULL;
store->blocks = 0;
store->size = 0;
@@ -44,6 +47,8 @@ _make_store (enum file_storage_class class, struct store_meths *meths)
store->class = class;
store->meths = meths;
+
+ store_set_runs (store, runs, runs_len); /* Also calls _store_derive(). */
}
return store;
}