mirror of
				https://gitlab.gnome.org/GNOME/glib.git
				synced 2025-10-31 08:22:16 +01:00 
			
		
		
		
	gioerror: Map ENOSYS to G_IO_ERROR_NOT_SUPPORTED
If a wrong syscall is used, we can assume that such feature is not supported at higher level.
This commit is contained in:
		| @@ -230,6 +230,12 @@ g_io_error_from_errno (gint err_no) | ||||
|       break; | ||||
| #endif | ||||
|  | ||||
| #ifdef ENOSYS | ||||
|     case ENOSYS: | ||||
|       return G_IO_ERROR_NOT_SUPPORTED; | ||||
|       break; | ||||
| #endif | ||||
|  | ||||
| #ifdef ETIMEDOUT | ||||
|     case ETIMEDOUT: | ||||
|       return G_IO_ERROR_TIMED_OUT; | ||||
|   | ||||
| @@ -322,7 +322,7 @@ test_error_from_errno (void) | ||||
|  | ||||
| #ifdef ENOSYS | ||||
|   g_assert_cmpuint (g_io_error_from_errno (ENOSYS), ==, | ||||
|                     G_IO_ERROR_FAILED); | ||||
|                     G_IO_ERROR_NOT_SUPPORTED); | ||||
| #endif | ||||
|  | ||||
| #ifdef ENOMSG | ||||
|   | ||||
		Reference in New Issue
	
	Block a user