coolkey/coolkey-implicit-declaration.patch

74 lines
2.9 KiB
Diff

https://bugzilla.redhat.com/show_bug.cgi?id=356971
In file included from object.cpp:22:
object.h:94: warning: type qualifiers ignored on function return type
object.cpp: In member function 'void PKCS11Object::getAttributeValue(CK_ATTRIBUTE*, CK_ULONG, Log*) const':
object.cpp:373: error: 'memcpy' was not declared in this scope
object.cpp: In member function 'const char* PKCS11Object::getLabel()':
object.cpp:417: error: 'memcpy' was not declared in this scope
object.cpp: In member function 'CK_OBJECT_CLASS PKCS11Object::getClass()':
object.cpp:442: error: 'memcpy' was not declared in this scope
object.cpp: In member function 'void PKCS11Object::setAttribute(CK_ATTRIBUTE_TYPE, const char*)':
object.cpp:465: error: 'strlen' was not declared in this scope
object.cpp: In function 'SECStatus GetCN(const CKYByte*, unsigned int, CCItem*)':
object.cpp:979: error: 'memcmp' was not declared in this scope
object.cpp: In function 'char* GetUserName(const CKYBuffer*)':
object.cpp:1010: error: 'memcpy' was not declared in this scope
machdep.cpp: In static member function 'static SHMem* SHMem::initSegment(const char*, int, bool&)':
machdep.cpp:328: error: 'strlen' was not declared in this scope
machdep.cpp:333: error: 'memcpy' was not declared in this scope
machdep.cpp:335: error: 'strcpy' was not declared in this scope
machdep.cpp:338: error: 'strcat' was not declared in this scope
machdep.cpp:348: error: 'calloc' was not declared in this scope
machdep.cpp:367: error: 'free' was not declared in this scope
log.cpp: In member function 'virtual void SysLog::log(const char*, ...)':
log.cpp:100: error: 'strlen' was not declared in this scope
log.cpp:100: error: 'malloc' was not declared in this scope
log.cpp:102: error: 'strcpy' was not declared in this scope
log.cpp:103: error: 'strcat' was not declared in this scope
log.cpp:106: error: 'free' was not declared in this scope
slot.cpp:36: error: 'std::auto_ptr' has not been declared
================================================================================
--- src/coolkey/log.cpp
+++ src/coolkey/log.cpp
@@ -21,6 +21,8 @@
#include "mypkcs11.h"
#include <assert.h>
#include <stdio.h>
+#include <string.h>
+#include <stdlib.h>
#include "log.h"
#include <cstdarg>
#include "PKCS11Exception.h"
--- src/coolkey/machdep.cpp
+++ src/coolkey/machdep.cpp
@@ -27,6 +27,8 @@
#include <unistd.h>
#include <errno.h>
#include <fcntl.h>
+#include <string.h>
+#include <stdlib.h>
#include <sys/file.h>
#include <sys/types.h>
#include <sys/time.h>
--- src/coolkey/object.cpp
+++ src/coolkey/object.cpp
@@ -21,6 +21,8 @@
#include "PKCS11Exception.h"
#include "object.h"
#include <algorithm>
+#include <string.h>
+#include <stdlib.h>
using std::find_if;
--- src/coolkey/slot.cpp
+++ src/coolkey/slot.cpp
@@ -18,6 +18,7 @@
* ***** END COPYRIGHT BLOCK *****/
#include <string>
+#include <memory>
#include "mypkcs11.h"
#include <stdio.h>
#include <assert.h>