Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(810)

Side by Side Diff: sandbox/linux/seccomp-bpf/sandbox_bpf.h

Issue 10825016: Fixed coverity defects regarding pass-by-value (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed non-compiling code caused by neglect to update header file Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef SANDBOX_BPF_H__ 5 #ifndef SANDBOX_BPF_H__
6 #define SANDBOX_BPF_H__ 6 #define SANDBOX_BPF_H__
7 7
8 #include <endian.h> 8 #include <endian.h>
9 #include <errno.h> 9 #include <errno.h>
10 #include <fcntl.h> 10 #include <fcntl.h>
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 } 315 }
316 } 316 }
317 317
318 // Get a file descriptor pointing to "/proc", if currently available. 318 // Get a file descriptor pointing to "/proc", if currently available.
319 static int getProcFd() { return proc_fd_; } 319 static int getProcFd() { return proc_fd_; }
320 320
321 private: 321 private:
322 friend class Util; 322 friend class Util;
323 friend class Verifier; 323 friend class Verifier;
324 struct Range { 324 struct Range {
325 Range(uint32_t f, uint32_t t, ErrorCode e) : 325 Range(uint32_t f, uint32_t t, const ErrorCode& e) :
326 from(f), 326 from(f),
327 to(t), 327 to(t),
328 err(e) { 328 err(e) {
329 } 329 }
330 uint32_t from, to; 330 uint32_t from, to;
331 ErrorCode err; 331 ErrorCode err;
332 }; 332 };
333 struct FixUp { 333 struct FixUp {
334 FixUp(unsigned int a, bool j) : 334 FixUp(unsigned int a, bool j) :
335 jt(j), addr(a) { } 335 jt(j), addr(a) { }
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 static Traps *traps_; 371 static Traps *traps_;
372 static TrapIds trapIds_; 372 static TrapIds trapIds_;
373 static ErrorCode *trapArray_; 373 static ErrorCode *trapArray_;
374 static size_t trapArraySize_; 374 static size_t trapArraySize_;
375 DISALLOW_IMPLICIT_CONSTRUCTORS(Sandbox); 375 DISALLOW_IMPLICIT_CONSTRUCTORS(Sandbox);
376 }; 376 };
377 377
378 } // namespace 378 } // namespace
379 379
380 #endif // SANDBOX_BPF_H__ 380 #endif // SANDBOX_BPF_H__
OLDNEW
« no previous file with comments | « chrome/browser/extensions/shell_window_registry.cc ('k') | sandbox/linux/seccomp-bpf/sandbox_bpf.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698