| Index: net/ftp/ftp_directory_parser.h
|
| ===================================================================
|
| --- net/ftp/ftp_directory_parser.h (revision 19238)
|
| +++ net/ftp/ftp_directory_parser.h (working copy)
|
| @@ -41,21 +41,20 @@
|
| #ifndef NET_FTP_FTP_DIRECTORY_PARSER_H_
|
| #define NET_FTP_FTP_DIRECTORY_PARSER_H_
|
|
|
| -#include <time.h>
|
|
|
| -#include "base/basictypes.h"
|
| +#include "base/time.h"
|
|
|
| namespace net {
|
|
|
| struct ListState {
|
| - void* magic; // to determine if previously initialized
|
| - int64 now_time; // needed for year determination.
|
| - struct tm now_tm; // needed for year determination.
|
| - int lstyle; // LISTing style.
|
| - int parsed_one; // returned anything yet?
|
| - char carry_buf[84]; // for VMS multiline.
|
| - unsigned int carry_buf_len; // length of name in carry_buf.
|
| - unsigned int numlines; // number of lines seen.
|
| + void* magic; // Determine if previously initialized.
|
| + bool now_tm_valid; // now_tm contains a valid time
|
| + base::Time::Exploded now_tm; // needed for year determination.
|
| + int lstyle; // LISTing style.
|
| + int parsed_one; // returned anything yet?
|
| + char carry_buf[84]; // for VMS multiline.
|
| + unsigned int carry_buf_len; // length of name in carry_buf.
|
| + unsigned int numlines; // number of lines seen.
|
| };
|
|
|
| enum LineType {
|
| @@ -67,15 +66,16 @@
|
| };
|
|
|
| struct ListResult {
|
| - LineType fe_type;
|
| - const char* fe_fname; // pointer to filename
|
| - unsigned int fe_fnlen; // length of filename
|
| - const char* fe_lname; // pointer to symlink name
|
| - unsigned int fe_lnlen; // length of symlink name
|
| - char fe_size[40]; // size of file in bytes (<= (2^128 - 1))
|
| - int fe_cinfs; // file system is definitely case insensitive
|
| - // TODO(ibrar): We should use "base::Time::Exploded" instead of "tm"
|
| - struct tm fe_time; // last-modified time
|
| + LineType fe_type;
|
| + const char* fe_fname; // pointer to filename
|
| + unsigned int fe_fnlen; // length of filename
|
| + const char* fe_lname; // pointer to symlink name
|
| + unsigned int fe_lnlen; // length of symlink name
|
| + char fe_size[40]; // size of file in bytes
|
| + // (<= (2^128 - 1))
|
| + int fe_cinfs; // file system is definitely
|
| + // case insensitive
|
| + base::Time::Exploded fe_time; // last-modified time
|
| };
|
|
|
| // ParseFTPLine() parses line from an FTP LIST command.
|
|
|