source: patches/glibc-2.5-sparc_fixes-1.patch@ 2a5f085

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 2a5f085 was 7707cfa, checked in by Jim Gifford <clfs@…>, 18 years ago

Glibc 2.5 Patches

  • Property mode set to 100644
File size: 2.5 KB
RevLine 
[7707cfa]1Submitted By: Jim Gifford (patches at jg555 dot com)
2Date: 2006-09-30
3Initial Package Version: 2.5
4Origin: Jakub Jelinek
5Upstream Status: Applied
6Description: Fixes for Sparc architecture
7 Fixes Missing Reference to __sigprocmask
8
9diff -Naur glibc-2.5.orig/sysdeps/unix/sysv/linux/sparc/sparc64/pause.c glibc-2.5/sysdeps/unix/sysv/linux/sparc/sparc64/pause.c
10--- glibc-2.5.orig/sysdeps/unix/sysv/linux/sparc/sparc64/pause.c 2006-08-14 22:27:23.000000000 -0700
11+++ glibc-2.5/sysdeps/unix/sysv/linux/sparc/sparc64/pause.c 2006-09-30 15:25:52.719786339 -0700
12@@ -1 +1,59 @@
13-#include <sysdeps/posix/pause.c>
14+/* pause -- suspend the process until a signal arrives. POSIX.1 version.
15+ Copyright (C) 2003 Free Software Foundation, Inc.
16+ This file is part of the GNU C Library.
17+
18+ The GNU C Library is free software; you can redistribute it and/or
19+ modify it under the terms of the GNU Lesser General Public
20+ License as published by the Free Software Foundation; either
21+ version 2.1 of the License, or (at your option) any later version.
22+
23+ The GNU C Library is distributed in the hope that it will be useful,
24+ but WITHOUT ANY WARRANTY; without even the implied warranty of
25+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
26+ Lesser General Public License for more details.
27+
28+ You should have received a copy of the GNU Lesser General Public
29+ License along with the GNU C Library; if not, write to the Free
30+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
31+ 02111-1307 USA. */
32+
33+#include <errno.h>
34+#include <signal.h>
35+#include <unistd.h>
36+#include <sysdep-cancel.h>
37+
38+#include <sysdep.h>
39+#include <sys/syscall.h>
40+#include <bp-checks.h>
41+
42+/* Suspend the process until a signal arrives.
43+ This always returns -1 and sets errno to EINTR. */
44+int
45+__libc_pause (void)
46+{
47+ sigset_t set;
48+
49+ __sigemptyset (&set);
50+ INLINE_SYSCALL (rt_sigprocmask, 4, SIG_BLOCK, CHECK_SIGSET (NULL),
51+ CHECK_SIGSET_NULL_OK (&set), _NSIG / 8);
52+
53+ /* pause is a cancellation point, but so is sigsuspend.
54+ So no need for anything special here. */
55+
56+ return __sigsuspend (&set);
57+}
58+weak_alias (__libc_pause, pause)
59+
60+LIBC_CANCEL_HANDLED (); /* sigsuspend handles our cancellation. */
61+
62+int
63+__pause_nocancel (void)
64+{
65+ sigset_t set;
66+
67+ __sigemptyset (&set);
68+ INLINE_SYSCALL (rt_sigprocmask, 4, SIG_BLOCK, CHECK_SIGSET (NULL),
69+ CHECK_SIGSET_NULL_OK (&set), _NSIG / 8);
70+ return INLINE_SYSCALL (rt_sigsuspend, 2, CHECK_SIGSET (&set), _NSIG / 8);
71+}
72+
Note: See TracBrowser for help on using the repository browser.