mirror of
				https://github.com/subsurface/subsurface.git
				synced 2025-02-19 22:16:15 +00:00 
			
		
		
		
	Dive site: pass dive-site pointer to delete_dive_site()
Instead of passing a uuid, pass a pointer to the dive site. This is small step in an effort to remove uuids. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
		
							parent
							
								
									8de471f90e
								
							
						
					
					
						commit
						f527a70831
					
				
					 8 changed files with 13 additions and 14 deletions
				
			
		|  | @ -890,7 +890,7 @@ static void save_divesites(git_repository *repo, struct dir *tree) | |||
| 				if (d->dive_site_uuid == ds->uuid) | ||||
| 					d->dive_site_uuid = 0; | ||||
| 			} | ||||
| 			delete_dive_site(ds->uuid); | ||||
| 			delete_dive_site(ds); | ||||
| 			i--; // since we just deleted that one
 | ||||
| 			continue; | ||||
| 		} else if (ds->name && | ||||
|  | @ -903,7 +903,7 @@ static void save_divesites(git_repository *repo, struct dir *tree) | |||
| 			if (!is_dive_site_used(ds, false)) { | ||||
| 				if (verbose) | ||||
| 					fprintf(stderr, "Deleted unused auto-created dive site %s\n", ds->name); | ||||
| 				delete_dive_site(ds->uuid); | ||||
| 				delete_dive_site(ds); | ||||
| 				i--; // since we just deleted that one
 | ||||
| 				continue; | ||||
| 			} | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue