This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
remote/2550: st_dev field not set for remote 'fstat' of file
- From: richard dot stuckey at arc dot com
- To: gdb-gnats at sources dot redhat dot com
- Date: 10 Nov 2008 16:01:53 -0000
- Subject: remote/2550: st_dev field not set for remote 'fstat' of file
- Reply-to: richard dot stuckey at arc dot com
>Number: 2550
>Category: remote
>Synopsis: st_dev field not set for remote 'fstat' of file
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Nov 10 16:08:01 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator: ARC International
>Release: 6.8
>Organization:
>Environment:
>Description:
The function target_fileio_to_fio_stat in file remote-fileio.c does not set the 'st_dev' field of the 'struct fio_stat' that it is constructing; there is a comment in the code that this is done by the calling function.
However, in the function remote_fileio_func_fstat (one of its callers), this is only done for the console_in/out files - the field is left undefined for other files.
The fix is to add the line
target_fileio_to_fio_uint (st.st_dev, fst.fst_dev);
to the 'else' part a few lines before the call to target_fileio_to_fio_stat, immediately after the call to fstat.
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: