$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [Boost-users] Why is asio clobbering my file before it can be sent?
From: Igor R (boost.lists_at_[hidden])
Date: 2011-08-18 04:10:45
>
> file_size = source_file.tellg();
> printf("foo.txt size: %d\n", (int) file_size); //size is now 0!
Before you call tellg, call seekg (0, ios::end)