public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: ajshower <ajshower@gmail.com>
To: cygwin@cygwin.com
Subject: Re: Redirecting output from running proc doesn't modify the "last modified time" field for target file
Date: Fri, 02 Dec 2011 18:43:00 -0000	[thread overview]
Message-ID: <32904332.post@talk.nabble.com> (raw)
In-Reply-To: <CAG_2cTn_1UHZy-13ACu-EPMaUSSSOr38s1_Rc0ccmdS2JDyJSQ@mail.gmail.com>


>IMHO, this is a very dubious "feature" to depend upon.  If you want to
>know if the file has changed, why not check its length instead?

I have switched to using the length instead but I was interested in what
people thought of the issue.

I'm having trouble reproducing this using just Cygwin so I'm not presenting
the problem accurately.  My process is to call  Runtime.getRuntime.exec()
within a java process which opens cygwin/bin/bash.exe and then runs the
redirection command from within the bash.  From the same java process that
called exec(), I'm trying to monitor the last modified time based on what's
going on in the previously called bash.exe.  That does sound pretty
convoluted.  I guess it's some kind of scope problem, but checking length()
is working, so it's all moot anyway.

I'll close this thread.

-Alex
-- 
View this message in context: http://old.nabble.com/Redirecting-output-from-running-proc-doesn%27t-modify-the-%22last-modified-time%22-field-for-target-file-tp32903475p32904332.html
Sent from the Cygwin list mailing list archive at Nabble.com.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

  reply	other threads:[~2011-12-02 18:43 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-02 16:51 ajshower
2011-12-02 17:20 ` Jon Clugston
2011-12-02 18:43   ` ajshower [this message]
2011-12-02 18:50     ` Jon Clugston
2011-12-02 20:05       ` Eric Blake
2011-12-03 20:37         ` Corinna Vinschen
2011-12-03 20:58           ` Christopher Faylor
2011-12-02 20:23   ` Eliot Moss

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=32904332.post@talk.nabble.com \
    --to=ajshower@gmail.com \
    --cc=cygwin@cygwin.com \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).