add fallback to the old dunstrc path
This commit is contained in:
		
							parent
							
								
									78b6e2b19f
								
							
						
					
					
						commit
						a5f64fc938
					
				
							
								
								
									
										5
									
								
								dunst.c
									
									
									
									
									
								
							
							
						
						
									
										5
									
								
								dunst.c
									
									
									
									
									
								
							| @ -1066,11 +1066,16 @@ parse_dunstrc(void) { | ||||
|     xdgInitHandle(&xdg); | ||||
| 
 | ||||
|     config_file = xdgConfigOpen("dunst/dunstrc", "r", &xdg); | ||||
|     if (config_file == NULL) { | ||||
|         /* Fall back to just "dunstrc", which was used before 2012-06-23
 | ||||
|          * (before v0.2). */ | ||||
|         config_file = xdgConfigOpen("dunstrc", "r", &xdg); | ||||
|         if (config_file == NULL) { | ||||
|             puts("no dunstrc found -> skipping\n"); | ||||
|             xdgWipeHandle(&xdg); | ||||
|             return; | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     if (ini_parse_file(config_file, dunst_ini_handle, NULL) < 0) { | ||||
|         puts("dunstrc could not be parsed -> skipping\n"); | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Michael Stapelberg
						Michael Stapelberg