make content's of file in binary form to zero and convert them back

Discussion in 'C Programming' started by Kelsey Bjarnason, Feb 5, 2008.

  1. Re: make content's of file in binary form to zero and convert themback

    On Tue, 05 Feb 2008 20:33:09 -0800, checoo wrote:

    > I am trying to change the content's of a file in binary form to zero and
    > then again change them back.
    >
    > Can anyone help me with this.


    Sure:

    1) Make copy of file
    2) Determine number of bytes to write
    3) Write 0 bytes to original file
    4) Copy duplicate file back to original file
    5) Optionally remove duplicated file

    Sum total effect of operation: spin the disk a while. Assuming the file
    is on a disk.
    Kelsey Bjarnason, Feb 5, 2008
    #1
    1. Advertising

  2. Re: make content's of file in binary form to zero and convert themback

    On Wed, 06 Feb 2008 20:05:04 +1300, Ian Collins wrote:

    > Kelsey Bjarnason wrote:
    >
    > When are you going to fix your clock?


    Err... why? Seems to be okay at this end. Says 1:39 AM now, and it's
    1:39 AM.
    Kelsey Bjarnason, Feb 6, 2008
    #2
    1. Advertising

  3. Kelsey Bjarnason

    checoo Guest

    I am trying to change the content's of a file in binary form to zero
    and then again change them back.

    Can anyone help me with this.

    Thank's in advance
    checoo, Feb 6, 2008
    #3
  4. Kelsey Bjarnason

    Ian Collins Guest

    Re: make content's of file in binary form to zero and convert themback

    checoo wrote:
    > I am trying to change the content's of a file in binary form to zero
    > and then again change them back.
    >

    Why?

    > Can anyone help me with this.
    >

    A bit more detail would help.

    --
    Ian Collins.
    Ian Collins, Feb 6, 2008
    #4
  5. Kelsey Bjarnason

    Ian Collins Guest

    Re: make content's of file in binary form to zero and convert themback

    Kelsey Bjarnason wrote:

    When are you going to fix your clock?

    --
    Ian Collins.
    Ian Collins, Feb 6, 2008
    #5
  6. Kelsey Bjarnason

    CBFalconer Guest

    Re: make content's of file in binary form to zero and convert them back

    Kelsey Bjarnason wrote:
    > Ian Collins wrote:
    >
    >> When are you going to fix your clock?

    >
    > Err... why? Seems to be okay at this end. Says 1:39 AM now,
    > and it's 1:39 AM.


    I see nothing wrong, assuming he is sending from the GMT timezone.

    --
    [mail]: Chuck F (cbfalconer at maineline dot net)
    [page]: <http://cbfalconer.home.att.net>
    Try the download section.



    --
    Posted via a free Usenet account from http://www.teranews.com
    CBFalconer, Feb 6, 2008
    #6
  7. Re: make content's of file in binary form to zero and convert themback

    In article <>,
    Kelsey Bjarnason <> wrote:

    >Err... why? Seems to be okay at this end. Says 1:39 AM now, and it's
    >1:39 AM.


    Your post has this header:

    Date: Wed Feb 06 01:40:22 GMT 2008

    and is a reply to Ian's which has this header:

    Date: Wed Feb 06 07:05:04 GMT 2008

    so clearly one of you has the wrong time.

    Since according to my server Ian's arrived at 07:09 GMT and yours arrived
    at 09:50 GMT, I'd guess that it's yours that is wrong.

    My guess is that you are 8 hours behind GMT and have your timezone set
    wrong.

    -- Richard
    --
    :wq
    Richard Tobin, Feb 6, 2008
    #7
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Zhiqiang Ye
    Replies:
    53
    Views:
    10,219
    Dan Pop
    Jun 28, 2004
  2. Gerard Flanagan
    Replies:
    3
    Views:
    431
    Terry Hancock
    Nov 19, 2005
  3. Harlin Seritt
    Replies:
    29
    Views:
    1,161
    Paul Rubin
    Feb 24, 2007
  4. Christopher Benson-Manica

    Doubles and zero/negative zero

    Christopher Benson-Manica, Jun 30, 2004, in forum: C Programming
    Replies:
    4
    Views:
    659
    Walter
    Jul 1, 2004
  5. why the lucky stiff
    Replies:
    5
    Views:
    134
    why the lucky stiff
    Sep 22, 2004
Loading...

Share This Page