Skip to content

Commit

Permalink
#1456 Resolves issue with shutdown when no sdrplay api is available. …
Browse files Browse the repository at this point in the history
…Version update to 0.6.0 alpha-2 (#1457)

Co-authored-by: Dennis Sheirer <dsheirer@github.com>
  • Loading branch information
DSheirer and Dennis Sheirer committed Feb 19, 2023
1 parent 75347f9 commit fc13777
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 12 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Expand Up @@ -30,7 +30,7 @@ repositories {
maven { url "https://jitpack.io" }
}

version = '0.6.0-alpha1'
version = '0.6.0-alpha2'

//Java 19 is required for this version of the Project Panama preview/incubator feature
java {
Expand Down
Expand Up @@ -561,21 +561,28 @@ private Status open()
*/
public Status close()
{
Status closeStatus;

try
if(mSdrplayLibraryLoaded)
{
closeStatus = Status.fromValue(sdrplay_api_h.sdrplay_api_Close());
Status closeStatus;

try
{
closeStatus = Status.fromValue(sdrplay_api_h.sdrplay_api_Close());
}
catch(Exception e)
{
closeStatus = Status.FAIL;
mLog.error("Error closing SDRPlay API", e);
}

mSdrplayLibraryLoaded = false;
mAvailable = false;
return closeStatus;
}
catch(Exception e)
else
{
closeStatus = Status.FAIL;
mLog.error("Error closing SDRPlay API", e);
return Status.API_UNAVAILABLE;
}

mSdrplayLibraryLoaded = false;
mAvailable = false;
return closeStatus;
}

/**
Expand Down

0 comments on commit fc13777

Please sign in to comment.