(!1896) os-support: systemd-logind: don't hard-crash Xserver on strdup() fail
No need to directly hard-crash the Xserver when strdup() fails, instead try to handle the situation gracefully. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
		
							parent
							
								
									11af1b975c
								
							
						
					
					
						commit
						d3a22bca2b
					
				|  | @ -492,7 +492,11 @@ connect_hook(DBusConnection *connection, void *data) | |||
|                    error.message); | ||||
|         goto cleanup; | ||||
|     } | ||||
|     session = XNFstrdup(session); | ||||
|     session = strdup(session); | ||||
|     if (!session) { | ||||
|         LogMessage(X_ERROR, "systemd-logind: out of memory\n"); | ||||
|         goto cleanup; | ||||
|     } | ||||
| 
 | ||||
|     dbus_message_unref(reply); | ||||
|     reply = NULL; | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue