From: Christos Margiolis <christos@margiolis.net>
To: 9front@9front.org
Subject: [9front] [PATCH] Fix fdclose conflict in drawterm
Date: Fri, 8 Oct 2021 01:34:21 +0300 [thread overview]
Message-ID: <20211007223421.dl6zb7jlfo7nzcox@pleb> (raw)
[-- Attachment #1: Type: text/plain, Size: 89 bytes --]
On FreeBSD fdclose(3) is declared as:
int
fdclose(FILE *stream, int *fdp);
--
Christos
[-- Attachment #2: 9front_sysfile.diff --]
[-- Type: text/x-diff, Size: 608 bytes --]
diff --git a/kern/sysfile.c b/kern/sysfile.c
index 04af4e3..413c0eb 100644
--- a/kern/sysfile.c
+++ b/kern/sysfile.c
@@ -293,7 +293,7 @@ _sysopen(char *name, int mode)
}
static void
-fdclose(int fd, int flag)
+_fdclose(int fd, int flag)
{
int i;
Chan *c;
@@ -325,7 +325,7 @@ long
_sysclose(int fd)
{
fdtochan(fd, -1, 0, 0);
- fdclose(fd, 0);
+ _fdclose(fd, 0);
return 0;
}
@@ -698,7 +698,7 @@ bindmount(int ismount, int fd, int afd, char* arg0, char* arg1, int flag, char*
poperror();
cclose(c0);
if(ismount){
- fdclose(fd, 0);
+ _fdclose(fd, 0);
poperror();
free(spec);
}
next reply other threads:[~2021-10-08 1:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-07 22:34 Christos Margiolis [this message]
2021-10-08 12:46 ` cinap_lenrek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211007223421.dl6zb7jlfo7nzcox@pleb \
--to=christos@margiolis.net \
--cc=9front@9front.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).