summaryrefslogtreecommitdiff
path: root/Cryptlib/SysCall/BaseStrings.c
diff options
context:
space:
mode:
Diffstat (limited to 'Cryptlib/SysCall/BaseStrings.c')
-rw-r--r--Cryptlib/SysCall/BaseStrings.c62
1 files changed, 31 insertions, 31 deletions
diff --git a/Cryptlib/SysCall/BaseStrings.c b/Cryptlib/SysCall/BaseStrings.c
index 2267d862..252e6db3 100644
--- a/Cryptlib/SysCall/BaseStrings.c
+++ b/Cryptlib/SysCall/BaseStrings.c
@@ -1,4 +1,4 @@
-#include <CrtLibSupport.h>
+#include <OpenSslSupport.h>
char *
AsciiStrCat(char *Destination, char *Source)
@@ -64,36 +64,6 @@ AsciiStrSize(CHAR8 *string)
return strlena(string) + 1;
}
-/* Based on AsciiStrDecimalToUintnS() in edk2
- * MdePkg/Library/BaseLib/SafeString.c */
-UINTN
-AsciiStrDecimalToUintn(const char *String)
-{
- UINTN Result;
-
- if (String == NULL)
- return 0;
-
- /* Ignore the pad spaces (space or tab) */
- while ((*String == ' ') || (*String == '\t')) {
- String++;
- }
-
- /* Ignore leading Zeros after the spaces */
- while (*String == '0') {
- String++;
- }
-
- Result = 0;
-
- while (*String >= '0' && *String <= '9') {
- Result = Result * 10 + (*String - '0');
- String++;
- }
-
- return Result;
-}
-
int
strcmp (const char *str1, const char *str2)
{
@@ -123,3 +93,33 @@ strcasecmp (const char *str1, const char *str2)
return c1 - c2;
}
+
+/* Based on AsciiStrDecimalToUintnS() in edk2
+ * MdePkg/Library/BaseLib/SafeString.c */
+UINTN
+AsciiStrDecimalToUintn(const char *String)
+{
+ UINTN Result;
+
+ if (String == NULL)
+ return 0;
+
+ /* Ignore the pad spaces (space or tab) */
+ while ((*String == ' ') || (*String == '\t')) {
+ String++;
+ }
+
+ /* Ignore leading Zeros after the spaces */
+ while (*String == '0') {
+ String++;
+ }
+
+ Result = 0;
+
+ while (*String >= '0' && *String <= '9') {
+ Result = Result * 10 + (*String - '0');
+ String++;
+ }
+
+ return Result;
+}