summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <cgf@redhat.com>2003-02-27 15:10:21 +0000
committerChristopher Faylor <cgf@redhat.com>2003-02-27 15:10:21 +0000
commit8762951e1db488d9f84e67e1007f0d54a675f70e (patch)
tree9d06eef2f7d7aa8dccd775d588218449623c13d3
parent3cbf1466d1290a6b74d643599f747db57410ac21 (diff)
downloadgdb-8762951e1db488d9f84e67e1007f0d54a675f70e.tar.gz
merge from trunk
-rw-r--r--winsup/cygwin/ChangeLog18
-rw-r--r--winsup/cygwin/ChangeLog.branch5
-rw-r--r--winsup/cygwin/cygthread.cc2
-rwxr-xr-xwinsup/cygwin/cygwin-gperf14
-rw-r--r--winsup/cygwin/devices.gperf6
-rw-r--r--winsup/cygwin/mmap.cc2
-rw-r--r--winsup/cygwin/sec_helper.cc3
-rw-r--r--winsup/cygwin/syslog.cc3
8 files changed, 41 insertions, 12 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 6c313cde75b..4065d80c879 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,21 @@
+2003-02-27 Christopher Faylor <cgf@redhat.com>
+
+ * cygthread::detach: Improve error message.
+
+2003-02-26 Pierre Humblet <pierre.humblet@ieee.org>
+
+ * sec_helper.cc (get_sids_info): debug_print owner_sid and group_sid.
+
+2003-02-25 Corinna Vinschen <corinna@vinschen.de>
+
+ * mmap.cc (mmap64): Fix returned address by taking the granularity
+ into account.
+
+2003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
+
+ * syslog.cc (syslog): Do not unlock the file before closing it
+ and remove debug_printf about stream errors.
+
2003-02-22 Christopher Faylor <cgf@redhat.com>
* cygmalloc.h: Remove MORECORE_CANNOT_TRIM. It's not true.
diff --git a/winsup/cygwin/ChangeLog.branch b/winsup/cygwin/ChangeLog.branch
index 83c8445a8ac..0fcc2910016 100644
--- a/winsup/cygwin/ChangeLog.branch
+++ b/winsup/cygwin/ChangeLog.branch
@@ -1,3 +1,8 @@
+2003-02-24 Christopher Faylor <cgf@redhat.com>
+
+ * device.gperf: Remove nonsensical devices.
+ * cygwin-gperf: Special case some devices.
+
2003-02-23 Christopher Faylor <cgf@redhat.com>
* cygwin-gperf: Fix typo in FH_FS static storage.
diff --git a/winsup/cygwin/cygthread.cc b/winsup/cygwin/cygthread.cc
index 2099f19bea5..ca57a9a467a 100644
--- a/winsup/cygwin/cygthread.cc
+++ b/winsup/cygwin/cygthread.cc
@@ -288,7 +288,7 @@ cygthread::detach (HANDLE sigwait)
w4[1] = *this;
res = WaitForSingleObject (sigwait, INFINITE);
if (res != WAIT_OBJECT_0)
- system_printf ("WFSO sigwait failed, res %u", res);
+ system_printf ("WFSO sigwait %p failed, res %u, %E", sigwait, res);
res = WaitForMultipleObjects (2, w4, FALSE, INFINITE);
if (res != WAIT_OBJECT_0)
/* nothing */;
diff --git a/winsup/cygwin/cygwin-gperf b/winsup/cygwin/cygwin-gperf
index 4a989af0578..3b083732a01 100755
--- a/winsup/cygwin/cygwin-gperf
+++ b/winsup/cygwin/cygwin-gperf
@@ -18,7 +18,10 @@ my %fh_declare = (
'fs_dev' => '&fs_dev_storage',
'proc_dev' => '&proc_dev_storage',
'registry_dev' => '&registry_dev_storage',
- 'process_dev' => '&process_dev_storage'
+ 'process_dev' => '&process_dev_storage',
+ 'piper_dev' => '&piper_dev_storage',
+ 'pipew_dev' => '&pipew_dev_storage',
+ 'socket_dev' => '&socket_dev_storage'
);
foreach (@lines) {
@@ -46,6 +49,15 @@ static const device registry_dev_storage =
static const device process_dev_storage =
{"", FH_PROCESS, "", 0, 0, 0, 0};
+static const device socket_dev_storage =
+ {"", FH_SOCKET, "", 0, 0, 0, 0};
+
+static const device piper_dev_storage =
+ {"", FH_PIPER, "", 0, 0, 0, 0};
+
+static const device pipew_dev_storage =
+ {"", FH_PIPEW, "", 0, 0, 0, 0};
+
EOF
for my $f (sort keys %fh_declare) {
$_ .= "const device *$f = $fh_declare{$f};\n";
diff --git a/winsup/cygwin/devices.gperf b/winsup/cygwin/devices.gperf
index 8e013e3a6b9..5251f59f302 100644
--- a/winsup/cygwin/devices.gperf
+++ b/winsup/cygwin/devices.gperf
@@ -34,13 +34,7 @@ struct device;
"/dev/com", FH_SERIAL, "\\.\\com%d", 1, 99
"/dev/ttyS", FH_SERIAL, "\\.\\com%d", 0, 99, -1
"/dev/pipe", FH_PIPE, "\\dev\\pipe", 0, 0, 0, 0
-"/dev/piper", FH_PIPER, "\\dev\\piper", 0, 0, 0, 0
-"/dev/pipew", FH_PIPEW, "\\dev\\pipew", 0, 0, 0, 0
"/dev/fifo", FH_FIFO, "\\dev\\fifo", 0, 0, 0, 0
-"/dev/streamsocket", FH_SOCKET, "\\dev\\socket", 0, 0, 0, 0
-"/dev/tcp", FH_SOCKET, "\\dev\\socket", 0, 0, 0, 0
-"/dev/udp", FH_SOCKET, "\\dev\\socket", 0, 0, 0, 0
-"/dev/dgsocket", FH_SOCKET, "\\dev\\socket", 0, 0, 0, 0
"/dev/st", FH_TAPE, "\\Device\\Tape%d", 0, 127
"/dev/nst", FH_NTAPE, "\\Device\\Tape%d", 0, 127
"/dev/fd", FH_FLOPPY, "\\Device\\Floppy%d", 0, 15
diff --git a/winsup/cygwin/mmap.cc b/winsup/cygwin/mmap.cc
index 920f93e3ea4..f28721ac8b8 100644
--- a/winsup/cygwin/mmap.cc
+++ b/winsup/cygwin/mmap.cc
@@ -578,7 +578,7 @@ mmap64 (caddr_t addr, size_t len, int prot, int flags, int fd, __off64_t off)
/* Insert into the list */
mmap_record *rec = map_list->add_record (mmap_rec, off, len);
- caddr_t ret = rec->get_address () + off;
+ caddr_t ret = rec->get_address () + (off - gran_off);
syscall_printf ("%x = mmap() succeeded", ret);
ReleaseResourceLock (LOCK_MMAP_LIST, READ_LOCK | WRITE_LOCK, "mmap");
return ret;
diff --git a/winsup/cygwin/sec_helper.cc b/winsup/cygwin/sec_helper.cc
index e5d8d6f5cb9..95c851ae4bc 100644
--- a/winsup/cygwin/sec_helper.cc
+++ b/winsup/cygwin/sec_helper.cc
@@ -193,6 +193,9 @@ get_sids_info (cygpsid owner_sid, cygpsid group_sid, __uid32_t * uidret, __gid32
struct __group32 *gr = NULL;
bool ret = false;
+ owner_sid.debug_print ("get_sids_info: owner SID =");
+ group_sid.debug_print ("get_sids_info: group SID =");
+
if (group_sid == cygheap->user.groups.pgsid)
*gidret = myself->gid;
else if ((gr = internal_getgrsid (group_sid)))
diff --git a/winsup/cygwin/syslog.cc b/winsup/cygwin/syslog.cc
index 761708f1d3f..67629b2f900 100644
--- a/winsup/cygwin/syslog.cc
+++ b/winsup/cygwin/syslog.cc
@@ -406,9 +406,6 @@ syslog (int priority, const char *message, ...)
fputs (timestamp, fp);
fputs (msg_strings[0], fp);
fputc ('\n', fp);
- UnlockFile (fHandle, 0, 0, 1, 0);
- if (ferror (fp))
- debug_printf ("error in writing syslog");
fclose (fp);
}
}