[CLATJ#26] ClatCoordinator: reword clatd starting failure logging

Bug: 212345928
Test: build
Change-Id: Ie826477d27db26cc49d113ec8bfacaaa3006e26e
This commit is contained in:
Hungming Chen
2022-01-26 17:12:45 +08:00
committed by Nucca Chen
parent 1ff914a543
commit 6fb21144b8
2 changed files with 2 additions and 2 deletions

View File

@@ -220,7 +220,7 @@ public class ClatCoordinator {
@NonNull final IpPrefix nat64Prefix)
throws IOException {
if (mIface != null || mPid != INVALID_PID) {
throw new IOException("Clatd has started on " + mIface + " (pid " + mPid + ")");
throw new IOException("Clatd is already running on " + mIface + " (pid " + mPid + ")");
}
if (nat64Prefix.getPrefixLength() != 96) {
throw new IOException("Prefix must be 96 bits long: " + nat64Prefix);

View File

@@ -340,7 +340,7 @@ public class ClatCoordinatorTest {
inOrder.verifyNoMoreInteractions();
// [2] Start clatd again failed.
assertThrows("java.io.IOException: Clatd has started on test0 (pid 10483)",
assertThrows("java.io.IOException: Clatd is already running on test0 (pid 10483)",
IOException.class,
() -> coordinator.clatStart(BASE_IFACE, NETID, NAT64_IP_PREFIX));