Make sure to implement the cryptodev engine only when /dev/crypto exists.
PR: 385
This commit is contained in:
parent
fabf7d3a67
commit
ae0b7667a9
@ -46,6 +46,18 @@ ENGINE_load_cryptodev(void)
|
|||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
|
|
||||||
|
#if OpenBSD < 200112
|
||||||
|
|
||||||
|
void
|
||||||
|
ENGINE_load_cryptodev(void)
|
||||||
|
{
|
||||||
|
/* This is a NOP unless we have release 3.0 (released december 2001) */
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
#else /* OpenBSD 3.0 or above */
|
||||||
|
|
||||||
#include <crypto/cryptodev.h>
|
#include <crypto/cryptodev.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
@ -1114,4 +1126,5 @@ ENGINE_load_cryptodev(void)
|
|||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif /* OpenBSD 3.0 or above */
|
||||||
#endif /* __OpenBSD__ */
|
#endif /* __OpenBSD__ */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user