(1892) xkb: ddxLoad: don't crash the server when strcpy() fails
No need for RunXkbComp() to hard-crash (by calling XNFstrdup()) the server if strdup() fails to allocate more memory - it's callers already handling the situation gracefully. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
		
							parent
							
								
									a80fdc9c7d
								
							
						
					
					
						commit
						9284d82d03
					
				| 
						 | 
					@ -194,7 +194,7 @@ RunXkbComp(xkbcomp_buffer_callback callback, void *userdata)
 | 
				
			||||||
#ifdef WIN32
 | 
					#ifdef WIN32
 | 
				
			||||||
            unlink(tmpname);
 | 
					            unlink(tmpname);
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
            return XNFstrdup(keymap);
 | 
					            return strdup(keymap);
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        else {
 | 
					        else {
 | 
				
			||||||
            LogMessage(X_ERROR, "Error compiling keymap (%s) executing '%s'\n",
 | 
					            LogMessage(X_ERROR, "Error compiling keymap (%s) executing '%s'\n",
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue