+int update_header()
+{
+ struct header* head = NULL;
+ head = gom_get_header();
+ if (head == NULL)
+ return 1;
+ else {
+ char* value;
+ int result, i;
+
+ value = gom_set_string(&head->source.id, PROG_NAME);
+ if (value == NULL || strcmp (value, PROG_NAME))
+ return 1;
+
+ value = gom_set_string(&head->source.name, NULL);
+ if (value != NULL)
+ return 1;
+
+ value = gom_set_string(&head->source.version, VERSION);
+ if (value == NULL || strcmp (value, VERSION))
+ return 1;
+
+ value = gom_set_string(&head->source.corporation.name, NULL);
+ if (value != NULL)
+ return 1;
+
+ if (head->source.corporation.address) {
+ result = gom_delete_address(&head->source.corporation.address);
+ if (result != 0)
+ return 1;
+ }
+
+ for (i=0; i<3; i++) {
+ if (head->source.corporation.phone[i]) {
+ value = gom_set_string(&head->source.corporation.phone[i], NULL);
+ if (value != NULL)
+ return 1;
+ }
+ }
+
+ return 0;
+ }
+}
+