mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 09:43:57 +00:00
e190a85f49
Dart code did not expect OSError as a return value from Socket_GetPort. This CL ensures that Dart code handles OSError in addition to int gracefully as a result of Socket_GetPort call. Fixes https://github.com/dart-lang/sdk/issues/45116 TEST=run dart ci socket tests on mac with transparent proxy running Change-Id: I198d99107729ccefecd9a16b71474ccdbfc0039b Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193221 Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Alexander Aprelev <aam@google.com>
26 lines
619 B
C++
26 lines
619 B
C++
// Copyright (c) 2021, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
#include "bin/utils.h"
|
|
|
|
#include <errno.h> // NOLINT
|
|
|
|
#include "bin/builtin.h"
|
|
#include "bin/dartutils.h"
|
|
|
|
#include "include/dart_api.h"
|
|
|
|
#include "platform/globals.h"
|
|
#include "platform/utils.h"
|
|
|
|
namespace dart {
|
|
namespace bin {
|
|
|
|
void FUNCTION_NAME(OSError_inProgressErrorCode)(Dart_NativeArguments args) {
|
|
Dart_SetIntegerReturnValue(args, EINPROGRESS);
|
|
}
|
|
|
|
} // namespace bin
|
|
} // namespace dart
|