mirror of
				https://github.com/postgres/postgres.git
				synced 2025-10-31 00:03:57 -04:00 
			
		
		
		
	Fix double frees in ecpg.
Patch by Patrick Krecker <patrick@judicata.com>
This commit is contained in:
		
							parent
							
								
									1e22166e5e
								
							
						
					
					
						commit
						db2fc801f6
					
				| @ -327,6 +327,7 @@ main(int argc, char *const argv[]) | ||||
| 						fprintf(stderr, _("%s: could not open file \"%s\": %s\n"), | ||||
| 								progname, output_filename, strerror(errno)); | ||||
| 						free(output_filename); | ||||
| 						output_filename = NULL; | ||||
| 						free(input_filename); | ||||
| 						continue; | ||||
| 					} | ||||
| @ -474,8 +475,10 @@ main(int argc, char *const argv[]) | ||||
| 				} | ||||
| 			} | ||||
| 
 | ||||
| 			if (output_filename && out_option == 0) | ||||
| 			if (output_filename && out_option == 0) { | ||||
| 				free(output_filename); | ||||
| 				output_filename = NULL; | ||||
| 			} | ||||
| 
 | ||||
| 			free(input_filename); | ||||
| 		} | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user