| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "nacl_io/dir_node.h" | 5 #include "nacl_io/dir_node.h" |
| 6 | 6 |
| 7 #include <errno.h> | 7 #include <errno.h> |
| 8 #include <string.h> | 8 #include <string.h> |
| 9 | 9 |
| 10 #include "nacl_io/osdirent.h" | 10 #include "nacl_io/osdirent.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 } | 36 } |
| 37 | 37 |
| 38 Error DirNode::Read(const HandleAttr& attr, | 38 Error DirNode::Read(const HandleAttr& attr, |
| 39 void* buf, | 39 void* buf, |
| 40 size_t count, | 40 size_t count, |
| 41 int* out_bytes) { | 41 int* out_bytes) { |
| 42 *out_bytes = 0; | 42 *out_bytes = 0; |
| 43 return EISDIR; | 43 return EISDIR; |
| 44 } | 44 } |
| 45 | 45 |
| 46 Error DirNode::FTruncate(off_t size) { return EISDIR; } | 46 Error DirNode::FTruncate(off_t size) { |
| 47 return EISDIR; |
| 48 } |
| 47 | 49 |
| 48 Error DirNode::Write(const HandleAttr& attr, | 50 Error DirNode::Write(const HandleAttr& attr, |
| 49 const void* buf, | 51 const void* buf, |
| 50 size_t count, | 52 size_t count, |
| 51 int* out_bytes) { | 53 int* out_bytes) { |
| 52 *out_bytes = 0; | 54 *out_bytes = 0; |
| 53 return EISDIR; | 55 return EISDIR; |
| 54 } | 56 } |
| 55 | 57 |
| 56 Error DirNode::GetDents(size_t offs, | 58 Error DirNode::GetDents(size_t offs, |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 | 125 |
| 124 cache_built_ = true; | 126 cache_built_ = true; |
| 125 } | 127 } |
| 126 | 128 |
| 127 void DirNode::ClearCache_Locked() { | 129 void DirNode::ClearCache_Locked() { |
| 128 cache_built_ = false; | 130 cache_built_ = false; |
| 129 cache_.Reset(); | 131 cache_.Reset(); |
| 130 } | 132 } |
| 131 | 133 |
| 132 } // namespace nacl_io | 134 } // namespace nacl_io |
| OLD | NEW |