-
Notifications
You must be signed in to change notification settings - Fork 273
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/divyagayathri-hcl/sonic-s…
…wss-common into zmq_new
- Loading branch information
Showing
33 changed files
with
662 additions
and
258 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,33 @@ | ||
#include "util.h" | ||
|
||
using namespace swss; | ||
|
||
bool swss::cApiTestingDisableAbort = false; | ||
|
||
SWSSString SWSSString_new(const char *data, uint64_t length) { | ||
SWSSTry(return makeString(std::string(data, numeric_cast<std::string::size_type>(length)))); | ||
} | ||
|
||
SWSSString SWSSString_new_c_str(const char *c_str) { | ||
SWSSTry(return makeString(std::string(c_str))); | ||
} | ||
|
||
const char *SWSSStrRef_c_str(SWSSStrRef s) { | ||
SWSSTry(return ((std::string *)s)->c_str()); | ||
} | ||
|
||
uint64_t SWSSStrRef_length(SWSSStrRef s) { | ||
SWSSTry(return ((std::string *)s)->length()); | ||
} | ||
|
||
void SWSSString_free(SWSSString s) { | ||
SWSSTry(delete (std::string *)s); | ||
} | ||
|
||
void SWSSFieldValueArray_free(SWSSFieldValueArray arr) { | ||
SWSSTry(delete[] arr.data); | ||
} | ||
|
||
void SWSSKeyOpFieldValuesArray_free(SWSSKeyOpFieldValuesArray kfvs) { | ||
SWSSTry(delete[] kfvs.data); | ||
} |
Oops, something went wrong.