diff --git a/cui/source/options/optjava.hxx b/cui/source/options/optjava.hxx
index 5950d4280c45..ca5ac45688d1 100644
--- a/cui/source/options/optjava.hxx
+++ b/cui/source/options/optjava.hxx
@@ -37,7 +37,7 @@
// forward ---------------------------------------------------------------
#if HAVE_FEATURE_JAVA
-typedef struct _JavaInfo JavaInfo;
+struct JavaInfo;
#else
typedef void* JavaInfo;
#endif
diff --git a/include/jvmfwk/framework.hxx b/include/jvmfwk/framework.hxx
index a85e38b2e796..9ba49ceee988 100644
--- a/include/jvmfwk/framework.hxx
+++ b/include/jvmfwk/framework.hxx
@@ -215,7 +215,7 @@ typedef enum _javaFrameworkError
For convenience this API provides the function jfw_freeJavaInfo
which frees the objects properly.
JavaInfo
object.
@param pInfo
The object which is to be freed. It can be NULL;