diff options
author | Nan Xiao <nan@chinadtrace.org> | 2020-09-29 14:24:21 +0800 |
---|---|---|
committer | Dan McDonald <danmcd@joyent.com> | 2020-09-30 10:26:17 -0400 |
commit | 6310a43a82652c7bf86384a7ab264bd3bfe2b23c (patch) | |
tree | 548da68a3eef9b471282faedd68775194db01ef2 /usr/src | |
parent | 7bb0fe31b7400cab73629832ea525813b9eeec17 (diff) | |
download | illumos-gate-6310a43a82652c7bf86384a7ab264bd3bfe2b23c.tar.gz |
13189 Update rename(2) man page
Reviewed by: C Fraire <cfraire@me.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Diffstat (limited to 'usr/src')
-rw-r--r-- | usr/src/man/man2/rename.2 | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/usr/src/man/man2/rename.2 b/usr/src/man/man2/rename.2 index 6780e534da..cc418fc954 100644 --- a/usr/src/man/man2/rename.2 +++ b/usr/src/man/man2/rename.2 @@ -4,11 +4,10 @@ .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] -.TH RENAME 2 "Oct 4, 2007" +.TH RENAME 2 "Sep 29, 2020" .SH NAME rename, renameat \- change the name of a file .SH SYNOPSIS -.LP .nf #include <stdio.h> @@ -24,7 +23,6 @@ rename, renameat \- change the name of a file .fi .SS "XPG3" -.LP .nf #include <unistd.h> @@ -32,8 +30,6 @@ rename, renameat \- change the name of a file .fi .SH DESCRIPTION -.sp -.LP The \fBrename()\fR function changes the name of a file. The \fIold\fR argument points to the pathname of the file to be renamed. The \fInew\fR argument points to the new path name of the file. @@ -155,14 +151,10 @@ Upon successful completion, the \fBrename()\fR and \fBrenameat()\fR functions will mark for update the \fBst_ctime\fR and \fBst_mtime\fR fields of the parent directory of each file. .SH RETURN VALUES -.sp -.LP Upon successful completion, \fB0\fR is returned. Otherwise, \fB\(mi1\fR is returned and \fBerrno\fR is set to indicate an error. .SH ERRORS -.sp -.LP -The \fBrename()\fR function will fail if: +The \fBrename()\fR and \fBrenameat()\fR functions will fail if: .sp .ne 2 .na @@ -335,7 +327,7 @@ The links named by \fIold\fR and \fInew\fR are on different file systems. .sp .LP -The \fBrenameat()\fR functions will fail if: +The \fBrenameat()\fR function will fail if: .sp .ne 2 .na @@ -347,8 +339,6 @@ an attribute file as a regular file. .RE .SH ATTRIBUTES -.sp -.LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp @@ -367,13 +357,9 @@ Standard For \fBrename()\fR, see \fBstandards\fR(5). .TE .SH SEE ALSO -.sp -.LP \fBchmod\fR(2), \fBlink\fR(2), \fBunlink\fR(2), \fBattributes\fR(5), \fBfsattr\fR(5), \fBstandards\fR(5) .SH NOTES -.sp -.LP The system can deadlock if there is a loop in the file system graph. Such a loop can occur if there is an entry in directory \fBa\fR, \fBa/name1\fR, that is a hard link to directory \fBb\fR, and an entry in directory \fBb\fR, |