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

Side by Side Diff: runtime/bin/platform_win.cc

Issue 584023004: Service isolate rework (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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 | « runtime/bin/platform_macos.cc ('k') | runtime/bin/resources_sources.gypi » ('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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "platform/globals.h" 5 #include "platform/globals.h"
6 #if defined(TARGET_OS_WINDOWS) 6 #if defined(TARGET_OS_WINDOWS)
7 7
8 #include "bin/platform.h" 8 #include "bin/platform.h"
9 #include "bin/log.h" 9 #include "bin/log.h"
10 #include "bin/socket.h" 10 #include "bin/socket.h"
(...skipping 14 matching lines...) Expand all
25 GetSystemInfo(&info); 25 GetSystemInfo(&info);
26 return info.dwNumberOfProcessors; 26 return info.dwNumberOfProcessors;
27 } 27 }
28 28
29 29
30 const char* Platform::OperatingSystem() { 30 const char* Platform::OperatingSystem() {
31 return "windows"; 31 return "windows";
32 } 32 }
33 33
34 34
35 const char* Platform::LibraryExtension() {
36 return "dll";
37 }
38
39
35 bool Platform::LocalHostname(char *buffer, intptr_t buffer_length) { 40 bool Platform::LocalHostname(char *buffer, intptr_t buffer_length) {
36 if (!Socket::Initialize()) return false; 41 if (!Socket::Initialize()) return false;
37 return gethostname(buffer, buffer_length) == 0; 42 return gethostname(buffer, buffer_length) == 0;
38 } 43 }
39 44
40 45
41 char** Platform::Environment(intptr_t* count) { 46 char** Platform::Environment(intptr_t* count) {
42 wchar_t* strings = GetEnvironmentStringsW(); 47 wchar_t* strings = GetEnvironmentStringsW();
43 if (strings == NULL) return NULL; 48 if (strings == NULL) return NULL;
44 wchar_t* tmp = strings; 49 wchar_t* tmp = strings;
(...skipping 23 matching lines...) Expand all
68 for (intptr_t i = 0; i < count; i++) { 73 for (intptr_t i = 0; i < count; i++) {
69 free(env[i]); 74 free(env[i]);
70 } 75 }
71 delete[] env; 76 delete[] env;
72 } 77 }
73 78
74 } // namespace bin 79 } // namespace bin
75 } // namespace dart 80 } // namespace dart
76 81
77 #endif // defined(TARGET_OS_WINDOWS) 82 #endif // defined(TARGET_OS_WINDOWS)
OLDNEW
« no previous file with comments | « runtime/bin/platform_macos.cc ('k') | runtime/bin/resources_sources.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698