Calling C API on Linux

Hello!

I have the problem that I cannot get Domino to create an encrypted database on our Linux server. The code works perfect on Windows but refuses to work on Linux, yes even after updating the library reference.

I use following declarations:

Const DBCLASS_NOTEFILE = &Hff01
Const DBCREATE_LOCALSECURITY = 1
Const DBCREATE_LARGE_UNKTABLE = &H8000
Const DBCREATE_ENCRYPT_STRONG = 3
Declare Function NSFDbCreateExtended Lib “libnotes.so” (ByVal DbPath As String, ByVal nClass As Long, ByVal ForceCreation As Long, ByVal Options As Long, ByVal EncryptStrength As Long, ByVal MaxFileSize As Long) As Integer

and do the following call:

NSFDbCreateExtended(destPath, DBCLASS_NOTEFILE, True, DBCREATE_LOCALSECURITY + DBCREATE_LARGE_UNKTABLE, DBCREATE_ENCRYPT_STRONG, 0)

As said before, this code works on Windows but not on Linux… Any idea?

Thank you very much in advance

Jens

Subject: problem solved

Hello,

I found out why the call did not work as expected. I used an absolute path as filename - e.g. \folder\database.nsf . On windows this will be interpreted as “absolute below the data folder” but on Linux I got an ERR_INVALID_NAME,“Remote pathnames must be relative to the Data directory”.
Leaving the leading slash/backslash did the trick. DOE

  • Jens