Commit graph

10 commits

Author SHA1 Message Date
jacob berkman
64a0eee134 fix improper use of guint as GType
2002-04-11  jacob berkman  <jacob@ximian.com>

	* (various files): fix improper use of guint as GType
2002-04-11 19:13:49 +00:00
Bradford Hovinen
6ab6caa498 Make backend_id const
2001-09-07  Bradford Hovinen  <hovinen@ximian.com>

	* archiver-client.c (location_client_store_xml): Make backend_id
	const

	* util.c (parse_date): Set the time zone
	(parse_date): Initialize tm_isdst

	* archiver-client.c (location_client_store_xml): Call
	ConfigArchiver_Location_storageComplete when done
	(location_client_store_xml): Don't try to save the XML file if
	there was an error getting the storage filename

	* location.c (location_storage_complete): Implement
	(impl_ConfigArchiver_Location_storageComplete): Implement

	* config-log.c (config_log_get_backend_id_for_id): Make return
	value const

2001-09-04  Bradford Hovinen  <hovinen@ximian.com>

	* location.c (location_get_storage_filename): Notify listeners
	that new rollback data is available

	* bonobo-config-archiver.c (new_rollback_cb): Implement
	(bonobo_config_archiver_new): Connect above to event source

	* location.c (location_store):
	(location_init): Construct an event source and add its interface

	* Makefile.am (INCLUDES): Remove -DDEFAULTS_DIR

2001-09-03  Bradford Hovinen  <hovinen@ximian.com>

	* bonobo-config-archiver.c (bonobo_config_archiver_new): Accept
	complete moniker as an argument; do the parsing here

	* archiver-client.c (location_client_load_rollback_data): Adjust
	time from mktime according to time zone information

	* bonobo-moniker-archiver.c (is_leap_year):
	(mod_date_by_str): Implement
	(parse_name): Use correct math for computing offsets

	* bonobo-config-archiver.c (bonobo_config_archiver_new): Don't
	print an error message if the parent moniker is bad
	(bonobo_config_archiver_new): Remove debugging messages

	* archiver-client.c (location_client_load_rollback_data): Make
	date and backend_id const

	* bonobo-moniker-archiver.c (archiverdb_resolve): Determine date
	from moniker and pass to bonobo_config_archiver_new

	* bonobo-config-archiver.c (bonobo_config_archiver_new): Accept
	date structure as argument
2001-09-12 15:30:41 +00:00
Bradford Hovinen (Gdict maintainer)
4e6a3b89d6 Added CORBA interface to the archiver 2001-08-20 15:47:57 +00:00
Bradford Hovinen
a1c5aa388f Return NULL if fgets returns NULL (dump_log): If both first_old and
2001-08-03  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c (load_log_entry): Return NULL if fgets returns NULL
	(dump_log): If both first_old and log_data are NULL, go ahead and
	dump the file, since nothing has been loaded yet
	(config_log_garbage_collect): Don't bother dumping the log file or
	reloading

2001-08-02  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c (config_log_garbage_collect): Implement
	(dump_log): Don't dump the old file if first_old is NULL

	* main.c (main): Support --garbage_collect

	* location.c (location_garbage_collect):
	(garbage_collect_cb): Implement
2001-08-03 14:38:09 +00:00
Bradford Hovinen
7631a53d80 Support STORE_DEFAULT (store_snapshot_cb): Use STORE_DEFAULT rather than
2001-05-03  Bradford Hovinen  <hovinen@ximian.com>

	* location.c (location_store_xml): Support STORE_DEFAULT
	(store_snapshot_cb): Use STORE_DEFAULT rather than STORE_MASK_PREVIOUS

	* location.h (_StoreType): Add STORE_DEFAULT

	* config-log.c (config_log_get_rollback_id_by_steps): Return the
	current id if the node represents default data

	* main.c (do_add_location): Cast correctly, fixing compiler
	warning
2001-05-04 01:28:38 +00:00
Bradford Hovinen
49876695d2 Added InputBuffer, removed get_line (struct _Slave): (struct
2001-04-20  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c: Added InputBuffer, removed get_line
	(struct _Slave):
	(struct _ConfigLogPrivate ): Replaced GIOChannel * and FILE * with
	InputBuffer *'s
	(input_buffer_new): Implement. Constructs a new input buffer
	(input_buffer_destroy): Implement. Destroys an input buffer and
	closes the file descriptor
	(input_buffer_cycle): Implement (borrowed from GDict). Reads
	additional data from the input file
	(input_buffer_read_line): Implement (borrowed from GDict). Reads a
	line from the input file and returns a pointer to it
	(input_buffer_write): Implement. Write the indicated string out to
	the channel

2001-04-15  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c (config_log_set_arg): Create semaphore for
	auto-reloading
	(do_load): Removed locking code
	(load_log_entry): Support prepending log entries to the beginning
	of the log; free entry->date if parsing was unsuccessful
	(config_log_reset_filenames): Unlink socket filename if not owner
	(config_log_reset_filenames): Rebind socket when filename is reset
	(connect_socket): Implement. Creates or connects to the socket
	associated with the config log
	(check_socket_filename): Implement. Checks to see if the filename
	associated with the socket is in use.
	(bind_socket): Implement. Binds the socket to the filename.
	(socket_connect_cb): Implement. Callback issued when a master gets
	a new connection.
	(socket_data_cb): Implement. Callback issued when a slave gets
	data from the master.
	(slave_new): Implement. Creates a new slave structure
	(slave_destroy): Implement. Destroys a slave structure
	(slave_data_cb): Implement. Callback issued when data comes in
	from a slave
	(slave_broadcast_data): Implement. Broadcast the first log entry
	to all the slaves except the given one
	(disconnect_socket): Implement. Disconnects the socket
	(config_log_open): Call connect_socket
	(do_unload): Don't dump the log unless currently the socket owner
	(config_log_write_entry): Broadcast data to slaves or write data
	to socket, depending on whether currently the socket owner

2001-04-14  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c (do_unload): Add a parameter write_log to tell
	whether to write out the log when unloading
	(config_log_finalize): Implement

	* config-log.[ch]: Put all data fields in ConfigLogPrivate
	structure

	* gui-backend-list.c (gui_backend_list_launch_current): Rewrite to
	use popen
2001-04-22 01:05:26 +00:00
Bradford Hovinen
afc3333a5a Added test-1.sh and test-2.sh, the first two tests in the test suite
2001-02-19  Bradford Hovinen  <hovinen@ximian.com>

	* Added test-1.sh and test-2.sh, the first two tests in the test suite

	* location.c (location_foreach_backend): Update to use BackendNote
	(do_rollback): Don't do rollback if the doc is NULL
	(location_store_xml): Return if this location does not contain the
	backend specified
	(location_store_xml): Use fprintf rather than g_warning
	(subtract_xml_node):
	(merge_xml_nodes): Update child node while iterating

	* config-log.c (config_log_get_rollback_ids_for_date): Remove

	* location.c (location_set_arg): ref inherited object

	* main.c (main): Don't check if the location is default; don't
	create default location if non-existant
	(main): Signal error if the user is adding a location and did not
	specify a name
	(main): Use fprintf to signal the error that a location could not
	be opened
	(main): Signal error and exit when archive cannot be opened,
	rather than using g_error
	(do_add_location): Check for NULL location_id
	(do_add_location): Create default location if it does not exist
	and it is specified as the parent

	* archive.c (archive_get_current_location_id): Create the default
	location if it does not exist

	* backend-list.c (backend_list_contains): Use strcmp and iterate
	through the list

	* location.c (location_contains): Read whether the backend is in
	the master list if this location is toplevel

2001-02-18  Bradford Hovinen  <hovinen@ximian.com>

	* main.c (do_add_backend): Support ContainmentType specification
	(do_store): Support StoreType specification
	(struct store_options): Add set of options to support
	compare_parent, mask_previous, options
	(struct add_remove_backend_options): Add option for partial
	containment when adding backend

	* location.c (subtract_xml_node):
	(merge_xml_nodes):
	(compare_xml_nodes):
	(merge_xml_docs):
	(subtract_xml_doc): Implement. XML node compare/merging operations
	(location_store): Rewrite to call location_store_xml
	(location_store_xml): Include support for diffing with
	configuration data from parent config
	(location_dump_rollback_data): Rewrite to use
	location_load_rollback_data
	(dump_xml_data): Remove
	(do_rollback): Rewrite to use xmlDocDump; pass xmlDocPtr rather
	than id number
	(location_rollback_id): Add node merging support
	(location_rollback_backend_by):
	(location_rollback_backend_to): Rewrite to use
	location_load_rollback_data
	(location_rollback_backends_to): Rewrite to iterate through
	backend list and call location_rollback_backend_to for each
	element
	(location_rollback_all_to): Ditto

2001-02-14  Bradford Hovinen  <hovinen@ximian.com>

	* location.h (_ContainmentType): Introduce. Specifies the type of
	containment (full, partial, none), of a backend in a location

	* location.c: Added struct BackendNote; have backend list include
	type of containment as well as backend id
	(location_contains): Use find_note
	(find_note): Implement. Finds a note for the given backend id in
	the backend list
	(backend_note_new):
	(backend_note_destroy): Implement. Convenience functions for
	creating and destroying backend notes
	(load_metadata_file):
	(write_metadata_file): Read/write type of backend containment
	(full or partial)
	(location_add_backend): Pass parameter telling whether containment
	is partial
2001-02-20 02:43:35 +00:00
Hans Petter
7beca6f9f9 Changed e-mail addresses: helixcode.com -> ximian.com. 2001-01-12 15:03:02 +00:00
Hans Petter
53acf19538 Updated copyright headers. 2001-01-12 14:40:26 +00:00
Bradford Hovinen
f089da2886 Added archiver directory Imported archiver for time travel, location
Tue Dec 19 09:04:00 2000  Bradford Hovinen  <hovinen@helixcode.com>

	* Makefile.am (SUBDIRS): Added archiver directory
	* archiver/*: Imported archiver for time travel, location management
2000-12-19 14:05:04 +00:00