Skip to content

Commit a197914

Browse files
committed
Remove iconv_allocation_t.
修改: ChangeLog 修改: include/cppp/reiconv.hpp.in 修改: lib/iconv.cpp
1 parent d3fe1be commit a197914

File tree

3 files changed

+1
-20
lines changed

3 files changed

+1
-20
lines changed

ChangeLog

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
Finish NLS Translate language maps (en_US, zh_CN).
44
Add Doxygen notes for 'cppp/reiconv.hpp'.
55
Fix 'reiconv_version' bug (changed it to 2.0).
6+
Remove 'iconv_allocation_t';
67

78
2023-07-19 ChenPi11 <wushengwuxi-msctinoulk@outlook.com>
89

include/cppp/reiconv.hpp.in

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -87,15 +87,6 @@ extern "C++"
8787
*/
8888
extern @DLL_VARIABLE@ int iconv_close (iconv_t cd);
8989

90-
// We will remove this typedef in the next commit, because function 'iconv_open_into was removed'.
91-
/* A type that holds all memory needed by a conversion descriptor.
92-
A pointer to such an object can be used as an iconv_t. */
93-
typedef struct
94-
{
95-
void* dummy1[28];
96-
mbstate_t dummy2;
97-
} iconv_allocation_t;
98-
9990
/**
10091
* @brief Control of attributes.
10192
* @param cd Conversion descriptor.

lib/iconv.cpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -270,17 +270,6 @@ namespace cppp{namespace base{namespace reiconv
270270
return 0;
271271
}
272272

273-
/*
274-
* Verify that a 'struct conv_struct' and a 'struct wchar_conv_struct' each
275-
* fit in an iconv_allocation_t.
276-
* If this verification fails, iconv_allocation_t must be made larger and
277-
* the major version in LIBICONV_VERSION_INFO must be bumped.
278-
* Currently 'struct conv_struct' has 23 integer/pointer fields, and
279-
* 'struct wchar_conv_struct' additionally has an 'mbstate_t' field.
280-
*/
281-
typedef int verify_size_1[2 * (sizeof (struct conv_struct) <= sizeof (iconv_allocation_t)) - 1];
282-
typedef int verify_size_2[2 * (sizeof (struct wchar_conv_struct) <= sizeof (iconv_allocation_t)) - 1];
283-
284273
/* Bit mask of all valid surfaces. */
285274
#define ALL_SURFACES (ICONV_SURFACE_EBCDIC_ZOS_UNIX)
286275

0 commit comments

Comments
 (0)