summaryrefslogtreecommitdiff
path: root/lib/ptsname_r.c
Commit message (Collapse)AuthorAgeFilesLines
* maint: run 'make update-copyright'Simon Josefsson2023-01-011-1/+1
|
* maint: run 'make update-copyright'Paul Eggert2022-01-011-1/+1
|
* ptsname_r: Drop sync with glibc.Bruno Haible2021-08-081-34/+19
| | | | | | | * lib/ptsname_r.c: Drop _LIBC code. (__set_errno, __isatty, __stat, __ttyname_r, __ptsname_r): Remove macros. (ptsname_r): Rename local variable 'save_errno'.
* ptsname_r: Add support for DragonFly BSD 6.0.Bruno Haible2021-06-081-0/+34
| | | | | * lib/ptsname_r.c (__ptsname_r): Add implementation for DragonFly BSD. * tests/test-ptsname_r.c (main): Treat Dragonfly BSD like Solaris.
* Put LGPLv2+ notices in source files where appropriate.Bruno Haible2021-06-041-7/+7
| | | | | * lib/**.{h,c,gperf}: Use LGPLv2+ notice whenever the module description says so.
* maint: run 'make update-copyright'Paul Eggert2020-12-311-1/+1
|
* ptsname_r: Fix test failure on Solaris.Bruno Haible2021-01-011-1/+1
| | | | | * lib/ptsname_r.c (__ptsname_r) [__sun]: Don't test the major number of the device.
* ptsname_r: Fix a compiler warning on Solaris.Bruno Haible2020-12-291-2/+1
| | | | * lib/ptsname_r.c (__ptsname_r): Reduce the scope of variable 'err'.
* stat failing with EOVERFLOW implies existencePaul Eggert2020-12-241-1/+1
| | | | | | | | | | | | | | | | | * lib/euidaccess.c (euidaccess): * lib/file-has-acl.c (file_has_acl): * lib/link.c (link, rpl_link): * lib/mkdir.c (rpl_mkdir): * lib/mkfifo.c (rpl_mkfifo): * lib/mknod.c (rpl_mknod): * lib/ptsname_r.c (__ptsname_r): * lib/symlink.c (rpl_symlink): * lib/symlinkat.c (rpl_symlinkat): * lib/unlink.c (rpl_unlink): * lib/unlinkat.c (rpl_unlinkat): * lib/utime.c (utime): If stat fails with EOVERFLOW the file exists, so treat it that way in file-existence tests that do not need struct stat values.
* maint: Run 'make update-copyright'Paul Eggert2019-12-311-1/+1
|
* ptsname_r: Work around bug on Android 4.3.Bruno Haible2019-01-261-11/+20
| | | | | | | | | | | * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Define HAVE_ESSENTIALLY_WORKING_PTSNAME_R. Test whether the return value is correct. * lib/ptsname_r.c (__ptsname_r): If HAVE_ESSENTIALLY_WORKING_PTSNAME_R is defined, just fix the return value. * doc/glibc-functions/ptsname_r.texi: Mention the Android bug. Reword: The behaviour of musl libc is nothing to be "fixed", since it is compliant with the next POSIX standard.
* maint: Run 'make update-copyright'Paul Eggert2019-01-011-1/+1
|
* maint: Run 'make update-copyright'Paul Eggert2018-01-011-1/+1
|
* all: Replace many more http URLs by https URLs. Update stale URLs.Bruno Haible2017-09-141-2/+2
| | | | | * users.txt: Remove mention of 'newts'. * lib/localename.c: Update comment about LANG_SOTHO.
* all: prefer https: URLsPaul Eggert2017-09-131-1/+1
|
* version-etc: new yearPaul Eggert2017-01-011-1/+1
| | | | | | | | | | * build-aux/gendocs.sh (version): * doc/gendocs_template: * doc/gendocs_template_min: * doc/gnulib.texi: * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright dates by hand in templates and the like. * all files: Run 'make update-copyright'.
* ptsname_r: leverage AC_HEADER_MAJORMike Frysinger2016-11-271-4/+8
| | | | | | | | | | | Like the mountlist module, ptsname_r uses makedev/major/minor, so use the existing autoconf macro which will probe some headers for use and set up some defines. * lib/ptsname_r.c: Likewise. [__sun]: Delete sys/sysmacros.h include. [_AIX || __osf__]: Likewise. * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Depend on AC_HEADER_MAJOR.
* maint: preprocessor changes to support z/OSDaniel Richard G2016-08-171-0/+5
| | | | | | | * lib/alloca.in.h, lib/fnmatch.c, lib/get-rusage-as.c: * lib/glob.c, lib/math.in.h, lib/ptsname_r.c: * tests/infinity.h, tests/nan.h, tests/test-canonicalize-lgpl.c: * tests/test-nonblocking-pipe.h:
* version-etc: new yearPaul Eggert2016-01-011-1/+1
| | | | | | | | | | * build-aux/gendocs.sh (version): * doc/gendocs_template: * doc/gendocs_template_min: * doc/gnulib.texi: * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright dates by hand in templates and the like. * all files: Run 'make update-copyright'.
* version-etc: new yearPaul Eggert2014-12-311-1/+1
| | | | | | * doc/gnulib.texi: * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date. * all files: Run 'make update-copyright'.
* maint: update copyrightEric Blake2014-01-011-1/+1
| | | | | | I ran 'make update-copyright'. Signed-off-by: Eric Blake <eblake@redhat.com>
* maint: update all copyright year number rangesEric Blake2013-01-011-1/+1
| | | | | | Run "make update-copyright". Compare to commit 1602f0a from last year. Signed-off-by: Eric Blake <eblake@redhat.com>
* ptsname_r: support ptys returned by FreeBSD posix_openptEric Blake2012-10-031-1/+2
| | | | | | | | | The recent change to ptsname exposed a latent bug in our ptsname_r implementation on FreeBSD 8.2 - there, posix_openpt returns a device where ttyname_r already lists it as /dev/pts/0. * lib/ptsname_r.c (__ptsname_r): Don't munge name if it already lives in /dev/pts/.
* ptsname_r: Fix typo in last commit.Bruno Haible2012-06-251-1/+1
|
* ptsname_r: Make it consistent with ptsname on AIX.Bruno Haible2012-06-251-3/+10
| | | | | | | * lib/ptsname_r.c (__ptsname_r): For AIX, use nearly the same implementation as for OSF/1. * tests/test-ptsname_r.c (main) [AIX]: Use the modern way of opening a pty master.
* ptsname_r: Make it consistent with ptsname on OSF/1.Bruno Haible2012-06-241-0/+37
| | | | | * lib/ptsname_r.c (__ptsname_r): Add a different implementation for OSF/1.
* ptsname_r: Add support for Solaris.Bruno Haible2012-06-241-0/+50
| | | | | * lib/ptsname_r.c (__ptsname_r): Add a different implementation for Solaris.
* ptsname_r: Fix test failures on IRIX, Solaris.Bruno Haible2012-06-241-2/+11
| | | | | | | | | | * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Test whether isatty sets errno when it fails. Define ISATTY_FAILS_WITHOUT_SETTING_ERRNO accordingly. * lib/ptsname_r.c: Include <fcntl.h>. (__ptsname_r): When isatty returned false, then on IRIX, Solaris set errno if fd is invalid. * tests/test-isatty.c (main): Update comments.
* maint: update all copyright year number rangesJim Meyering2012-01-011-1/+1
| | | | Run "make update-copyright".
* ptsname_r: new moduleEric Blake2011-11-091-0/+85
For now, this replacement focuses solely on compilation compatibility, and assumes that isatty() and ttyname_r() work on a master side pty; if this assumption fails, or if thread-safety is also required, then a later patch can follow the lead of strerror_r.c in wrapping the system ptsname() with a lock. * modules/ptsname_r: New module. * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): New file. * lib/ptsname.c (__ptsname_r): Split... * lib/ptsname_r.c: ...into new file. * m4/stdlib_h.m4 (gl_STDLIB_H): Check for decl. (gl_STDLIB_H_DEFAULTS): Set witness defaults. * modules/stdlib (Makefile.am): Substitute witnesses. * lib/stdlib.in.h (ptsname_r): Declare it. * doc/glibc-functions/ptsname_r.texi (ptsname_r): Document it. * MODULES.html.sh (Misc): Likewise. * modules/ptsname (Depends-on): Alter dependency. * doc/posix-functions/ptsname.texi (ptsname): Mention new module. Signed-off-by: Eric Blake <eblake@redhat.com>