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

Side by Side Diff: src/platform.h

Issue 50036: Add support for setting the SO_REUSEADDR option for sockets (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 9 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
« no previous file with comments | « no previous file | src/platform-freebsd.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after
441 441
442 // Shutdown socket for both read and write. This causes blocking Send and 442 // Shutdown socket for both read and write. This causes blocking Send and
443 // Receive calls to exit. After Shutdown the Socket object cannot be used for 443 // Receive calls to exit. After Shutdown the Socket object cannot be used for
444 // any communication. 444 // any communication.
445 virtual bool Shutdown() = 0; 445 virtual bool Shutdown() = 0;
446 446
447 // Data Transimission 447 // Data Transimission
448 virtual int Send(const char* data, int len) const = 0; 448 virtual int Send(const char* data, int len) const = 0;
449 virtual int Receive(char* data, int len) const = 0; 449 virtual int Receive(char* data, int len) const = 0;
450 450
451 // Set the value of the SO_REUSEADDR socket option.
452 virtual bool SetReuseAddress(bool reuse_address) = 0;
453
451 virtual bool IsValid() const = 0; 454 virtual bool IsValid() const = 0;
452 455
453 static bool Setup(); 456 static bool Setup();
454 static int LastError(); 457 static int LastError();
455 static uint16_t HToN(uint16_t value); 458 static uint16_t HToN(uint16_t value);
456 static uint16_t NToH(uint16_t value); 459 static uint16_t NToH(uint16_t value);
457 static uint32_t HToN(uint32_t value); 460 static uint32_t HToN(uint32_t value);
458 static uint32_t NToH(uint32_t value); 461 static uint32_t NToH(uint32_t value);
459 }; 462 };
460 463
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 bool active_; 510 bool active_;
508 PlatformData* data_; // Platform specific data. 511 PlatformData* data_; // Platform specific data.
509 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); 512 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler);
510 }; 513 };
511 514
512 #endif // ENABLE_LOGGING_AND_PROFILING 515 #endif // ENABLE_LOGGING_AND_PROFILING
513 516
514 } } // namespace v8::internal 517 } } // namespace v8::internal
515 518
516 #endif // V8_PLATFORM_H_ 519 #endif // V8_PLATFORM_H_
OLDNEW
« no previous file with comments | « no previous file | src/platform-freebsd.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698