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

Side by Side Diff: chrome/browser/extensions/api/serial/serial_api.cc

Issue 9307114: Coverity: Initialize member variables. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Win fix. Created 8 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
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 #include <string> 5 #include <string>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chrome/browser/extensions/api/serial/serial_api.h" 9 #include "chrome/browser/extensions/api/serial/serial_api.h"
10 #include "content/public/browser/browser_thread.h" 10 #include "content/public/browser/browser_thread.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 BrowserThread::UI, FROM_HERE, 43 BrowserThread::UI, FROM_HERE,
44 base::Bind(&SerialOpenFunction::RespondOnUIThread, this)); 44 base::Bind(&SerialOpenFunction::RespondOnUIThread, this));
45 DCHECK(rv); 45 DCHECK(rv);
46 } 46 }
47 47
48 void SerialOpenFunction::RespondOnUIThread() { 48 void SerialOpenFunction::RespondOnUIThread() {
49 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 49 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
50 SendResponse(true); 50 SendResponse(true);
51 } 51 }
52 52
53 SerialCloseFunction::SerialCloseFunction() { 53 SerialCloseFunction::SerialCloseFunction() : connection_id_(0) {
54 } 54 }
55 55
56 SerialCloseFunction::~SerialCloseFunction() { 56 SerialCloseFunction::~SerialCloseFunction() {
57 } 57 }
58 58
59 bool SerialCloseFunction::RunImpl() { 59 bool SerialCloseFunction::RunImpl() {
60 EXTENSION_FUNCTION_VALIDATE(args_->GetInteger(0, &connection_id_)); 60 EXTENSION_FUNCTION_VALIDATE(args_->GetInteger(0, &connection_id_));
61 61
62 bool rv = BrowserThread::PostTask( 62 bool rv = BrowserThread::PostTask(
63 BrowserThread::IO, FROM_HERE, 63 BrowserThread::IO, FROM_HERE,
(...skipping 13 matching lines...) Expand all
77 base::Bind(&SerialCloseFunction::RespondOnUIThread, this)); 77 base::Bind(&SerialCloseFunction::RespondOnUIThread, this));
78 DCHECK(rv); 78 DCHECK(rv);
79 } 79 }
80 80
81 void SerialCloseFunction::RespondOnUIThread() { 81 void SerialCloseFunction::RespondOnUIThread() {
82 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 82 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
83 SendResponse(true); 83 SendResponse(true);
84 } 84 }
85 85
86 } // namespace extensions 86 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698