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

Side by Side Diff: webrtc/base/thread.h

Issue 2668693005: Use correct calling convention for CreateThread callback on Windows. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | webrtc/base/thread.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 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 void SafeWrapCurrent(); 231 void SafeWrapCurrent();
232 232
233 // Blocks the calling thread until this thread has terminated. 233 // Blocks the calling thread until this thread has terminated.
234 void Join(); 234 void Join();
235 235
236 static void AssertBlockingIsAllowedOnCurrentThread(); 236 static void AssertBlockingIsAllowedOnCurrentThread();
237 237
238 friend class ScopedDisallowBlockingCalls; 238 friend class ScopedDisallowBlockingCalls;
239 239
240 private: 240 private:
241 #if defined(WEBRTC_WIN)
242 static DWORD WINAPI PreRun(LPVOID context);
243 #else
241 static void *PreRun(void *pv); 244 static void *PreRun(void *pv);
245 #endif
242 246
243 // ThreadManager calls this instead WrapCurrent() because 247 // ThreadManager calls this instead WrapCurrent() because
244 // ThreadManager::Instance() cannot be used while ThreadManager is 248 // ThreadManager::Instance() cannot be used while ThreadManager is
245 // being created. 249 // being created.
246 // The method tries to get synchronization rights of the thread on Windows if 250 // The method tries to get synchronization rights of the thread on Windows if
247 // |need_synchronize_access| is true. 251 // |need_synchronize_access| is true.
248 bool WrapCurrentWithThreadManager(ThreadManager* thread_manager, 252 bool WrapCurrentWithThreadManager(ThreadManager* thread_manager,
249 bool need_synchronize_access); 253 bool need_synchronize_access);
250 254
251 // Return true if the thread was started and hasn't yet stopped. 255 // Return true if the thread was started and hasn't yet stopped.
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 329
326 private: 330 private:
327 SocketServer* old_ss_; 331 SocketServer* old_ss_;
328 332
329 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(SocketServerScope); 333 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(SocketServerScope);
330 }; 334 };
331 335
332 } // namespace rtc 336 } // namespace rtc
333 337
334 #endif // WEBRTC_BASE_THREAD_H_ 338 #endif // WEBRTC_BASE_THREAD_H_
OLDNEW
« no previous file with comments | « no previous file | webrtc/base/thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698