Skip to content

Segmentation Fault in API when connection to Netconf fails #879

@ygorelik

Description

@ygorelik

Expected Behavior

When invoking YDK API the Netconf client fails to establish connection to server, the YDK should develop YServiceProviderException.

Current Behavior

When invoking YDK API the Netconf client fails to establish connection the YDK develops Segmentation Fault.

Steps to Reproduce

Run YDK C++ test codec_encode when Netconf server is down or specified IP address or port is incorrect.

Logs

yan@ubuntu-yan:~/ydk-workspace/ydk-gen/sdk/cpp/tests/build$ ./ydk_bundle_test codec_encode
[2019-02-19 08:21:03.189] [ydk] [error] Connection error occurred: Unable to connect to localhost:12022.
[2019-02-19 08:21:03.189] [ydk] [error] Could not connect to localhost

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ydk_bundle_test is a Catch v1.7.1 host application.
Run with -? for options

-------------------------------------------------------------------------------
codec_encode
-------------------------------------------------------------------------------
/home/yan/ydk-workspace/ydk-gen/sdk/cpp/tests/test_c_api.cpp:34
...............................................................................

/home/yan/ydk-workspace/ydk-gen/sdk/cpp/tests/test_c_api.cpp:34: FAILED:
due to a fatal error condition:
  SIGSEGV - Segmentation violation signal

===============================================================
test cases: 1 | 1 failed
assertions: 1 | 1 failed

Segmentation fault

System Information

YDK-0.8.1

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions