search for: dupfd

Displaying 10 results from an estimated 10 matches for "dupfd".

2015 Dec 07
2
[mesa v2 5/9] nouveau: fix screen creation failure paths
...> @@ -59,7 +59,7 @@ nouveau_drm_screen_create(int fd) > { > struct nouveau_device *dev = NULL; > struct nouveau_screen *(*init)(struct nouveau_device *); > - struct nouveau_screen *screen; > + struct nouveau_screen *screen = NULL; > int ret, dupfd = -1; > > pipe_mutex_lock(nouveau_screen_mutex); > @@ -117,7 +117,7 @@ nouveau_drm_screen_create(int fd) > } > > screen = init(dev); > - if (!screen) > + if (!screen || !screen->base.context_create) > goto err; > &...
2015 Dec 07
1
[mesa v2 5/9] nouveau: fix screen creation failure paths
...(int fd) >>> { >>> struct nouveau_device *dev = NULL; >>> struct nouveau_screen *(*init)(struct nouveau_device *); >>> - struct nouveau_screen *screen; >>> + struct nouveau_screen *screen = NULL; >>> int ret, dupfd = -1; >>> >>> pipe_mutex_lock(nouveau_screen_mutex); >>> @@ -117,7 +117,7 @@ nouveau_drm_screen_create(int fd) >>> } >>> >>> screen = init(dev); >>> - if (!screen) >>> + if (!screen || !scree...
2006 Jan 03
2
Bug ? on ssh-agent
Hi, I fell on this using openssh on cygwin. Though it may be a cygwin related issue, I think it's may be a bug on the main openssh tree. Thus my posting here. I'm CC'ing to the public list for information. The part of code I'm refering to is : /* XXX might close listen socket */ (void)dup2(fd, STDIN_FILENO); (void)dup2(fd, STDOUT_FILENO);
2015 Nov 27
0
[mesa v2 5/9] nouveau: fix screen creation failure paths
...nsys.c +++ b/src/gallium/winsys/nouveau/drm/nouveau_drm_winsys.c @@ -59,7 +59,7 @@ nouveau_drm_screen_create(int fd) { struct nouveau_device *dev = NULL; struct nouveau_screen *(*init)(struct nouveau_device *); - struct nouveau_screen *screen; + struct nouveau_screen *screen = NULL; int ret, dupfd = -1; pipe_mutex_lock(nouveau_screen_mutex); @@ -117,7 +117,7 @@ nouveau_drm_screen_create(int fd) } screen = init(dev); - if (!screen) + if (!screen || !screen->base.context_create) goto err; /* Use dupfd in hash table, to avoid errors if the original fd gets @@ -130,10 +130,14...
2014 Jun 19
1
[PATCH] nouveau: dup fd before passing it to device
nouveau screens are reused for the same device node. However in the scenario where we create screen 1, screen 2, and then delete screen 1, the surrounding code might also close the original device node. To protect against this, dup the fd and use the dup'd fd in the nouveau_device. Also tell the nouveau_device that it is the owner of the fd so that it will be closed on destruction. Also make
2015 Nov 27
13
[mesa v2 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com> Signed-off-by: Ben Skeggs <bskeggs at redhat.com> --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 4016871..c02ee61 100644 --- a/configure.ac +++ b/configure.ac @@ -73,7 +73,7 @@ LIBDRM_RADEON_REQUIRED=2.4.56 LIBDRM_AMDGPU_REQUIRED=2.4.63 LIBDRM_INTEL_REQUIRED=2.4.61
2015 Dec 07
0
[mesa v2 5/9] nouveau: fix screen creation failure paths
...ouveau_drm_screen_create(int fd) >> { >> struct nouveau_device *dev = NULL; >> struct nouveau_screen *(*init)(struct nouveau_device *); >> - struct nouveau_screen *screen; >> + struct nouveau_screen *screen = NULL; >> int ret, dupfd = -1; >> >> pipe_mutex_lock(nouveau_screen_mutex); >> @@ -117,7 +117,7 @@ nouveau_drm_screen_create(int fd) >> } >> >> screen = init(dev); >> - if (!screen) >> + if (!screen || !screen->base.context_create) >&...
2015 Nov 26
9
[mesa 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com> Signed-off-by: Ben Skeggs <bskeggs at redhat.com> --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 4016871..c02ee61 100644 --- a/configure.ac +++ b/configure.ac @@ -73,7 +73,7 @@ LIBDRM_RADEON_REQUIRED=2.4.56 LIBDRM_AMDGPU_REQUIRED=2.4.63 LIBDRM_INTEL_REQUIRED=2.4.61
2015 Dec 16
11
[mesa v3 1/9] nouveau: bump required libdrm version to 2.4.66
From: Ben Skeggs <bskeggs at redhat.com> v2. forgot bump for non-gallium driver Signed-off-by: Ben Skeggs <bskeggs at redhat.com> --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index b6680d0..965c6f7 100644 --- a/configure.ac +++ b/configure.ac @@ -72,8 +72,8 @@ LIBDRM_REQUIRED=2.4.60
2007 Aug 23
0
[git patch] klibc dash 0.5.4 update
...{ struct redirtab *q; q = ckmalloc(sizeof (struct redirtab)); q->next = redirlist; @@ -132,12 +132,11 @@ redirect(union node *redir, int flags) } n = redir; do { - fd = n->nfile.fd; - if ((n->nfile.type == NTOFD || n->nfile.type == NFROMFD) && - n->ndup.dupfd == fd) - continue; /* redirect from/to same file descriptor */ - newfd = openredirect(n); + if (newfd < -1) + continue; + + fd = n->nfile.fd; if (sv) { p = &sv->renamed[fd]; @@ -174,7 +173,7 @@ redirect(union node *redir, int flags) if (memory[2]) out2 = &mem...