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

Side by Side Diff: base/test/android/java/src/org/chromium/base/MultiprocessTestClientLauncher.java

Issue 2765453004: Moving FileDescriptorInfo from content/ to base/. (Closed)
Patch Set: Synced. Created 3 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 package org.chromium.base; 5 package org.chromium.base;
6 6
7 import android.content.ComponentName; 7 import android.content.ComponentName;
8 import android.content.Context; 8 import android.content.Context;
9 import android.content.Intent; 9 import android.content.Intent;
10 import android.content.ServiceConnection; 10 import android.content.ServiceConnection;
11 import android.os.IBinder; 11 import android.os.IBinder;
12 import android.os.ParcelFileDescriptor; 12 import android.os.ParcelFileDescriptor;
13 import android.os.RemoteException; 13 import android.os.RemoteException;
14 14
15 import org.chromium.base.annotations.CalledByNative; 15 import org.chromium.base.annotations.CalledByNative;
16 import org.chromium.base.annotations.JNINamespace; 16 import org.chromium.base.annotations.JNINamespace;
17 import org.chromium.base.process_launcher.FileDescriptorInfo;
17 18
18 import java.io.IOException; 19 import java.io.IOException;
19 import java.util.ArrayList; 20 import java.util.ArrayList;
20 import java.util.LinkedList; 21 import java.util.LinkedList;
21 import java.util.List; 22 import java.util.List;
22 import java.util.Queue; 23 import java.util.Queue;
23 24
24 import javax.annotation.concurrent.GuardedBy; 25 import javax.annotation.concurrent.GuardedBy;
25 26
26 /** 27 /**
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 } 282 }
282 283
283 private static FileDescriptorInfo makeFdInfo(int id, int fd) { 284 private static FileDescriptorInfo makeFdInfo(int id, int fd) {
284 ParcelFileDescriptor parcelableFd = null; 285 ParcelFileDescriptor parcelableFd = null;
285 try { 286 try {
286 parcelableFd = ParcelFileDescriptor.fromFd(fd); 287 parcelableFd = ParcelFileDescriptor.fromFd(fd);
287 } catch (IOException e) { 288 } catch (IOException e) {
288 Log.e(TAG, "Invalid FD provided for process connection, aborting con nection.", e); 289 Log.e(TAG, "Invalid FD provided for process connection, aborting con nection.", e);
289 return null; 290 return null;
290 } 291 }
291 return new FileDescriptorInfo(id, parcelableFd); 292 return new FileDescriptorInfo(id, parcelableFd, 0 /* offset */, 0 /* siz e */);
292 } 293 }
293 } 294 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698