mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-11-28 21:09:54 +01:00
Added AIX implementation of g_unix_fd_query_path
This commit is contained in:
committed by
Philip Withnall
parent
82d1b39426
commit
0328064e52
@@ -952,12 +952,14 @@ char *
|
||||
g_unix_fd_query_path (int fd,
|
||||
GError **error)
|
||||
{
|
||||
#if defined(__linux__) || defined(__sun)
|
||||
#if defined(__linux__) || defined(__sun) || defined(_AIX)
|
||||
char *path;
|
||||
char *proc_path;
|
||||
|
||||
#ifdef __sun
|
||||
proc_path = g_strdup_printf ("/proc/self/path/%d", fd);
|
||||
#elif _AIX
|
||||
proc_path = g_strdup_printf ("/proc/%ld/fd/%d", (long) getpid (), fd);
|
||||
#else
|
||||
proc_path = g_strdup_printf ("/proc/self/fd/%d", fd);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user