X-Git-Url: https://review.openocd.org/gitweb?p=openocd.git;a=blobdiff_plain;f=src%2Ftarget%2Fopenrisc%2Fjsp_server.c;fp=src%2Ftarget%2Fopenrisc%2Fjsp_server.c;h=1d05944bc73fc4149d0054323b7f8d292264a3a4;hp=f28815df9fc0af33a9ff0f72e99ba1362770b103;hb=3934483429b77525f25922787933fb7ee3e73a0f;hpb=0dad8cbfe9e1d43cdcabbc8eb4e2809b7b21381d diff --git a/src/target/openrisc/jsp_server.c b/src/target/openrisc/jsp_server.c index f28815df9f..1d05944bc7 100644 --- a/src/target/openrisc/jsp_server.c +++ b/src/target/openrisc/jsp_server.c @@ -190,12 +190,8 @@ static int jsp_connection_closed(struct connection *connection) if (ERROR_OK != retval) return retval; - if (connection->priv) { - free(connection->priv); - connection->priv = NULL; - } else - LOG_ERROR("BUG: connection->priv == NULL"); - + free(connection->priv); + connection->priv = NULL; return ERROR_OK; }