summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <monty@donna.mysql.fi>2001-03-26 16:49:11 +0300
committerunknown <monty@donna.mysql.fi>2001-03-26 16:49:11 +0300
commit219682ef86a240014dce8649a15380b390863f30 (patch)
tree5da4abd6f52ae4b0af895f7c6248e92e8ccd2721
parentf51f5985380f3f439478c910844e209fede40021 (diff)
downloadmariadb-git-219682ef86a240014dce8649a15380b390863f30.tar.gz
Fix a crash in Innobase with tables with many columns and a range query
Removed all Attic directories. BitKeeper/deleted/.del-myisam.doc~519bb06ecc870298: Delete: Docs/Attic/myisam.doc BitKeeper/deleted/.del-libmysql.c~72949a7043113807: Delete: client/Attic/libmysql.c BitKeeper/deleted/.del-net.c~c18042da6fa4e693: Delete: client/Attic/net.c BitKeeper/deleted/.del-print_defaults.c~362952979aa7b330: Delete: extra/Attic/print_defaults.c BitKeeper/deleted/.del-config-win32.h~65db818ec7e8f21b: Delete: include/Attic/config-win32.h BitKeeper/deleted/.del-m_ctype.h.in~f671e3c2d611ba97: Delete: include/Attic/m_ctype.h.in BitKeeper/deleted/.del-mysql_com.h.in~85b1ea7ced528c32: Delete: include/Attic/mysql_com.h.in BitKeeper/deleted/.del-ft_global.h~fe46fb515f1e375: Delete: myisam/Attic/ft_global.h BitKeeper/deleted/.del-lex_hash.h~14f912771118b50c: Delete: sql/Attic/lex_hash.h BitKeeper/deleted/.del-mini_client.c~9a3778c387d06a81: Delete: sql/Attic/mini_client.c BitKeeper/deleted/.del-mini_client_errors.c~29edad51a5d0b068: Delete: sql/Attic/mini_client_errors.c BitKeeper/deleted/.del-mybinlogdump.cc~5dbdd2bde98d6169: Delete: sql/Attic/mybinlogdump.cc BitKeeper/deleted/.del-net_serv.c~52dabcd773a39e10: Delete: sql/Attic/net_serv.c BitKeeper/deleted/.del-bootstrap-ctype.c~6d2a8cda2d6a35ff: Delete: strings/Attic/bootstrap-ctype.c BitKeeper/deleted/.del-ct_init.c~f0948bdd35ceedc3: Delete: strings/Attic/ct_init.c BitKeeper/deleted/.del-ctype-cp1251.c~cdf74b9168408b3: Delete: strings/Attic/ctype-cp1251.c BitKeeper/deleted/.del-ctype-cp1257.c~732611cbc74aeafc: Delete: strings/Attic/ctype-cp1257.c BitKeeper/deleted/.del-ctype-croat.c~d2d805ee6f10cbcc: Delete: strings/Attic/ctype-croat.c BitKeeper/deleted/.del-ctype-danish.c~dc5451066eb272ae: Delete: strings/Attic/ctype-danish.c BitKeeper/deleted/.del-ctype-dec8.c~68f257dd2202d0c7: Delete: strings/Attic/ctype-dec8.c BitKeeper/deleted/.del-ctype-dos.c~f77bd08acf13a8c1: Delete: strings/Attic/ctype-dos.c BitKeeper/deleted/.del-ctype-estonia.c~fc8a69424f7cb66b: Delete: strings/Attic/ctype-estonia.c BitKeeper/deleted/.del-ctype-german1.c~f7830c509bb358f7: Delete: strings/Attic/ctype-german1.c BitKeeper/deleted/.del-ctype-greek.c~90acdff1195209ca: Delete: strings/Attic/ctype-greek.c BitKeeper/deleted/.del-ctype-hebrew.c~d3b4a000d51e76dc: Delete: strings/Attic/ctype-hebrew.c BitKeeper/deleted/.del-ctype-hp8.c~749e1be0f028d349: Delete: strings/Attic/ctype-hp8.c BitKeeper/deleted/.del-ctype-hungarian.c~5cf0bf7fa0312637: Delete: strings/Attic/ctype-hungarian.c BitKeeper/deleted/.del-ctype-koi8_ru.c~8ff4188c642c9bd: Delete: strings/Attic/ctype-koi8_ru.c BitKeeper/deleted/.del-ctype-koi8_ukr.c~a04aa14a6d62335a: Delete: strings/Attic/ctype-koi8_ukr.c BitKeeper/deleted/.del-ctype-latin1.c~cc63880f19c2303e: Delete: strings/Attic/ctype-latin1.c BitKeeper/deleted/.del-ctype-latin2.c~31895c4b83654342: Delete: strings/Attic/ctype-latin2.c BitKeeper/deleted/.del-ctype-swe7.c~bb1b012225d7d02c: Delete: strings/Attic/ctype-swe7.c BitKeeper/deleted/.del-ctype-usa7.c~d19d859dca5675f: Delete: strings/Attic/ctype-usa7.c BitKeeper/deleted/.del-ctype-win1250.c~1ce7a24255780a1: Delete: strings/Attic/ctype-win1250.c BitKeeper/deleted/.del-ctype-win1251.c~762607f4fd7d52ad: Delete: strings/Attic/ctype-win1251.c BitKeeper/deleted/.del-ctype-win1251ukr.c~b5a7cca889bbef58: Delete: strings/Attic/ctype-win1251ukr.c BitKeeper/deleted/.del-ctype.c.in~8bf48d4bcbc5f675: Delete: strings/Attic/ctype.c.in BitKeeper/deleted/.del-memory.h~450f586e82a26d99: Delete: strings/Attic/memory.h BitKeeper/deleted/.del-ptr_cmp.c~57e682a26e769597: Delete: strings/Attic/ptr_cmp.c BitKeeper/deleted/.del-my-example.cnf.sh~87a7e1f4d24b62a9: Delete: support-files/Attic/my-example.cnf.sh BitKeeper/deleted/.del-my-huge.cfg.sh~589bdcd2d2c4360b: Delete: support-files/Attic/my-huge.cfg.sh BitKeeper/deleted/.del-my-large.cfg.sh~842c8e76253c9396: Delete: support-files/Attic/my-large.cfg.sh BitKeeper/deleted/.del-my-medium.cfg.sh~c49880d26ef0648e: Delete: support-files/Attic/my-medium.cfg.sh BitKeeper/deleted/.del-my-small.cfg.sh~85023c559a1d96c: Delete: support-files/Attic/my-small.cfg.sh sql/ha_innobase.cc: Fix a crash with tables with many columns and a range query: memory corruption occurred Docs/manual.texi: Changelog mysql-test/r/innobase.result: New test case for innobase scripts/mysql_install_db.sh: Fixed typo sql/ha_berkeley.h: Fixed that 'have_bdb' is disabled if we can't initialize bdb sql/ha_gemini.cc: Removed include file that got compiliation to fail on some systems sql/handler.cc: Fixed that 'have_tabltype' is disabled if we can't initialize it. sql/mysqld.cc: Fix bug that could cause a fast connect/close to fail when using --debug
-rw-r--r--Docs/Attic/myisam.doc901
-rw-r--r--Docs/manual.texi4
-rw-r--r--client/Attic/libmysql.c2392
-rw-r--r--client/Attic/net.c628
-rw-r--r--extra/Attic/print_defaults.c125
-rwxr-xr-xinclude/Attic/config-win32.h247
-rw-r--r--include/Attic/m_ctype.h.in231
-rwxr-xr-xinclude/Attic/mysql_com.h.in216
-rw-r--r--myisam/Attic/ft_global.h52
-rw-r--r--mysql-test/r/innobase.result2
-rw-r--r--scripts/mysql_install_db.sh1
-rw-r--r--sql/Attic/lex_hash.h416
-rw-r--r--sql/Attic/mini_client.c783
-rw-r--r--sql/Attic/mini_client_errors.c64
-rw-r--r--sql/Attic/mybinlogdump.cc138
-rw-r--r--sql/Attic/net_serv.c616
-rw-r--r--sql/ha_berkeley.h1
-rw-r--r--sql/ha_gemini.cc6
-rw-r--r--sql/ha_innobase.cc4
-rw-r--r--sql/handler.cc8
-rw-r--r--sql/mysqld.cc2
-rw-r--r--strings/Attic/bootstrap-ctype.c91
-rw-r--r--strings/Attic/ct_init.c6
-rw-r--r--strings/Attic/ctype-cp1251.c88
-rw-r--r--strings/Attic/ctype-cp1257.c88
-rw-r--r--strings/Attic/ctype-croat.c143
-rw-r--r--strings/Attic/ctype-danish.c144
-rw-r--r--strings/Attic/ctype-dec8.c140
-rw-r--r--strings/Attic/ctype-dos.c139
-rw-r--r--strings/Attic/ctype-estonia.c93
-rwxr-xr-xstrings/Attic/ctype-german1.c135
-rw-r--r--strings/Attic/ctype-greek.c855
-rw-r--r--strings/Attic/ctype-hebrew.c135
-rw-r--r--strings/Attic/ctype-hp8.c133
-rw-r--r--strings/Attic/ctype-hungarian.c113
-rw-r--r--strings/Attic/ctype-koi8_ru.c133
-rw-r--r--strings/Attic/ctype-koi8_ukr.c141
-rw-r--r--strings/Attic/ctype-latin1.c142
-rw-r--r--strings/Attic/ctype-latin2.c186
-rw-r--r--strings/Attic/ctype-swe7.c137
-rw-r--r--strings/Attic/ctype-usa7.c134
-rw-r--r--strings/Attic/ctype-win1250.c152
-rw-r--r--strings/Attic/ctype-win1251.c135
-rw-r--r--strings/Attic/ctype-win1251ukr.c142
-rw-r--r--strings/Attic/ctype.c.in20
-rw-r--r--strings/Attic/memory.h33
-rw-r--r--strings/Attic/ptr_cmp.c151
-rw-r--r--support-files/Attic/my-example.cnf.sh39
-rw-r--r--support-files/Attic/my-huge.cfg.sh60
-rw-r--r--support-files/Attic/my-large.cfg.sh60
-rw-r--r--support-files/Attic/my-medium.cfg.sh58
-rw-r--r--support-files/Attic/my-small.cfg.sh53
52 files changed, 15 insertions, 10901 deletions
diff --git a/Docs/Attic/myisam.doc b/Docs/Attic/myisam.doc
deleted file mode 100644
index e0b56e79548..00000000000
--- a/Docs/Attic/myisam.doc
+++ /dev/null
@@ -1,901 +0,0 @@
-#.# mi_changed()
-
-int mi_is_changed(MI_INFO *mip)
-
-#.#.1 Description
-
-Reports whether any changes have occurred to the MyISAM table associated with mip.
-
-For information only, I notice that mi_changed() is a wrapper around this: (_mi_readinfo(info,F_RDLCK,1)).
-
-#.#.2 Return values
-
-Zero if the table has not changed. Non-zero (-1) if the table has changed.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-if( mi_changed( mip )) printf( "file has changed" );
-====================
-#.# mi_close()
-
-int mi_close( MI_INFO *mip )
-
-#.#.1 Description
-
-Closes the MyISAM table associated with mip, a structure created by mi_open().
-Any locks on that file pointer are released.
-The MI_INFO structure mip is released.
-See also mi_panic() which can be used to close all open MyISAM files.
-mip is a pointer to the MI_INFO returned by mi_open().
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-result = mi_close(mip);
-====================
-#.# mi_create()
-
-int mi_create( const char *name, uint keys, MI_KEYDEF *keydefs,
- uint columns, MI_COLUMNDEF *recinfo,
- uint uniques, MI_UNIQUEDEF *uniquedefs,
- MI_CREATE_INFO *ci, uint flags )
-
-#.#.1 Description
-
-Creates a new MyISAM table.
-Documentation for this function is not complete because I am not using mi_create directly.
-Because all our tables are used with MySQL, I create new tables using SQL "CREATE TABLE" via the C API.
-See MySQL Appendix B "Choosing a table type".
-MyISAM allows about 32 indexes. However the official MySQL limit is 16 until MySQL 4.0.
-
-The parameters are specified as follows:
-name The file pathname, excluding the suffixes.
-keys Number of indexes.
-keydefs A MI_KEYDEF structure containing key definitions.
-HA_KEYTYPE_END=0
-HA_KEYTYPE_TEXT=1, /* Key is sorted as letters */
-HA_KEYTYPE_BINARY=2, /* Key is sorted as unsigned chars
-HA_KEYTYPE_SHORT_INT=3,
-HA_KEYTYPE_LONG_INT=4,
-HA_KEYTYPE_FLOAT=5,
-HA_KEYTYPE_DOUBLE=6,
-HA_KEYTYPE_NUM=7, /* Not packed num with pre-space *
-HA_KEYTYPE_USHORT_INT=8,
-HA_KEYTYPE_ULONG_INT=9,
-HA_KEYTYPE_LONGLONG=10,
-HA_KEYTYPE_ULONGLONG=11,
-HA_KEYTYPE_INT24=12,
-HA_KEYTYPE_UINT24=13,
-HA_KEYTYPE_INT8=14,
-HA_KEYTYPE_VARTEXT=15, /* Key is sorted as letters */
-HA_KEYTYPE_VARBINARY=16 /* Key is sorted as unsigned chars
-columns The number of columns.
-recinfo A MI_COLUMNDEF structure containing column definitions.
-uniques The number of unique indexes.
-uniquedefs A MI_UNIQUEDEF structure containing unique index definitions.
-ci A MI_CREATE_INFO structure containing column definitions.
-flags a pointer to the record buffer that will contain the row.
-
-#.#.2 Return values
-
-Zero if the create is successful. Non-zero if an error occurs.
-
-#.#.3 Errors
-
-HA_WRONG_CREATE_OPTION
- means that some of the arguments was wrong.
-appart from the above one can get any unix error that one can get from open(), write() or close().
-
-#.#.4 Examples
-
-if (mi_create(fn_format(name,filename,"",MI_NAME_IEXT, 4+ (opt_follow_links ? 16 : 0)),
- share.base.keys - share.state.header.uniques, keyinfo, share.base.fields, recdef,
- share.state.header.uniques, uniquedef, &create_info, HA_DONT_TOUCH_DATA))
-====================
-#.# mi_delete()
-
-int mi_delete(MI_INFO *mip, const byte *buf)
-
-#.#.1 Description
-
-Removes a row from a MyISAM table.
-
-mip is an MI_INFO pointer to the open handle.
-buf is the buffer containing the row that is to be deleted.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-EACCES
-File was opened read-only.
-HA_ERR_KEY_NOT_FOUND
-No database read
-HA_ERR_RECORD_CHANGED
-The buffer contents were different to the actual row contents.
-HA_ERR_CRASHED
-The indexing has crashed.
-
-#.#.4 Examples
-
-if (mi_delete(file,read_record))
-====================
-#.# mi_delete_all()
-
-int mi_delete_all_rows(MI_INFO *mip)
-#.#.1 Description
-
-Removes ALL rows from a MyISAM table.
-This only clears the status information. The files are not truncated.
-
-mip is an MI_INFO pointer to the open handle.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-EACCES
-File was opened read-only.
-
-#.#.4 Examples
-
-error = mi_delete_all( mip );
-====================
-#.# mi_extra()
-
-int mi_extra(MI_INFO *info, enum ha_extra_function function)
-
-#.#.1 Description
-
-Controls some special MyISAM modes.
-
-The function parameter can be:
- HA_EXTRA_NORMAL=0 Optimize for space (def)
-HA_EXTRA_QUICK=1 Optimize for speed
-HA_EXTRA_RESET=2 Reset database to after open
-HA_EXTRA_CACHE=3 Cash record in HA_rrnd()
-HA_EXTRA_NO_CACHE=4 End cacheing of records (def)
-HA_EXTRA_NO_READCHECK=5 No readcheck on update
-HA_EXTRA_READCHECK=6 Use readcheck (def)
-HA_EXTRA_KEYREAD=7 Read only key to database
-HA_EXTRA_NO_KEYREAD=8 Normal read of records (def)
-HA_EXTRA_NO_USER_CHANGE=9 No user is allowed to write
-HA_EXTRA_KEY_CACHE=10
-HA_EXTRA_NO_KEY_CACHE=11
-HA_EXTRA_WAIT_LOCK=12 Wait until file is avalably (def)
-HA_EXTRA_NO_WAIT_LOCK=13 If file is locked, return quickly
-HA_EXTRA_WRITE_CACHE=14 Use write cache in ha_write()
-HA_EXTRA_FLUSH_CACHE=15 flush write_record_cache
-HA_EXTRA_NO_KEYS=16 Remove all update of keys
-HA_EXTRA_KEYREAD_CHANGE_POS=17 Keyread, but change pos
-xxxxchk -r must be used
-HA_EXTRA_REMEMBER_POS=18 Remember pos for next/prev
-HA_EXTRA_RESTORE_POS=19
-HA_EXTRA_REINIT_CACHE=20 init cache from current record
-HA_EXTRA_FORCE_REOPEN=21 Datafile have changed on disk
-HA_EXTRA_FLUSH Flush tables to disk
-HA_EXTRA_NO_ROWS Don't write rows
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-====================
-#.# mi_make_application_key()
-
-void mi_make_application_key(register MI_INFO *mip, uint keynr, uchar *key, const byte *record)
-
-#.#.1 Description
-
-Construct a key string for the given index, from the provided record buffer.
-Monty wrote this function to: "to create an external key for an application from your record. It should work for all keys except BLOB and true VARCHAR (not supported by MySQL yet), but I don't think you have either of these!" He just wrote it, so I expect it to included in releases from about 3.23.15. ??
-
-The parameters are:
-A MI_INFO pointer mip.
-The index number keynr.
-The buffer to contain the formatted key string key.
-The record buffer record.
-
-#.#.2 Return values
-
-The byte length of the created key string.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-uint new_length=_mi_make_application_key(info,i,new_key,newrec);
-====================
-#.# mi_open()
-
-MI_INFO *mi_open( const char *name, int mode, uint handle_locking )
-
-#.#.1 Description
-
-Opens a MyISAM file for processing.
-mi_open() returns a MI_INFO structure pointer that you must use in subsequent operations on the MyISAM file. MI_INFO structures are defined in "myisam/myisamdef.h", which is included in your program via your include myisam.h - used by both MyISAM and MySQL.
-The name parameter must contain a null-terminated string without an extension, which is the filename of the MyISAM file to be processed.
-There is no automatic positioning nor key selection.
-Caution! It is extremely important to close MyISAM files after processing has finished, especially on operating systems without file-locking system calls. Failure to close MyISAM files using mi_close() or mi_panic() leaves the files locked on systems without these system calls.
-
-name Is the name of the file.
-mode Is the access mode parameter. Use one of the following access mode parameters:
-O_RDONLY to open for input only.
-O_RDWR opens the file for output.
-O_SHARE opens the file for both input and output. When used, O_SHARE should be added to O_RDONLY and O_RDWR.
-handle_locking is the locking mode parameter. Select from the following:
-HA_OPEN_ABORT_IF_LOCKED (0) exit with error if database is locked
-HA_OPEN_WAIT_IF_LOCKED (1) wait if database is locked
-HA_OPEN_IGNORE_IF_LOCKED (2) continue, but count-vars in st_i_info may be wrong. count-vars are automatically fixed after next isam request.
-
-#.#.2 Return values
-
-A pointer to MI_INFO for successfully open file. NULL if unsuccessful, when my_errno will contain the error code.
-
-#.#.3 Errors
-
-HA_ERR_OLD_FILE
-wrong options
-HA_ERR_CRASHED
-wrong header
-HA_ERR_UNSUPPORTED
-too many keys or keys too long
-HA_ERR_END_OF_FILE
-empty file?
-MY_FILE_ERROR
-?
-EACCES
-cannot open in write mode
-ENOMEM
-not enough memory
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-pfm = mi_open("/D1/adir/perform",O_SHARE | O_RDONLY, HA_OPEN_ABORT_IF_LOCKED);
-====================
-#.# mi_panic()
-
-int mi_panic( enum ha_panic_function flag )
-
-#.#.1 Description
-
-mi_panic() is used to close any MyISAM files before exiting, or to safeguard file updates when using a shell.
-The flag parameter specifies the function and can be:
-HA_PANIC_CLOSE Close all databases (MyISAM files).
-HA_PANIC_WRITE Unlock and write status, flushing all buffers to disk.
-HA_PANIC_READ Lock and read key info per HA_PANIC_WRITE.
-
-The CLOSE function also writes buffers before it closes and turns logging off by closing the log file..
-See also my_end(), a debugging function.
-One use is to do a WRITE, use a shell to run myisamchk, then do a READ.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-result = mi_panic(HA_PANIC_CLOSE);
-====================
-#.# mi_position()
-
-my_off_t mi_position(MI_INFO *mip)
-
-#.#.1 Description
-
-Gets the byte position in the file of the last record read.
-
-mip is an MI_INFO pointer to the open handle.
-
-#.#.2 Return values
-
-Byte position if successful. Zero if an error occurred. ??
-
-#.#.3 Errors
-
-HA_OFFSET_ERROR
-if there wasn't any active row.
-
-#.#.4 Examples
-
-currentpos = mi_position( mip );
-====================
-#.# mi_rfirst()
-
-int mi_rfirst(MI_INFO *mip , byte *buf, int inx)
-
-#.#.1 Description
-
-Reads the first row in the MyISAM file according to the specified index.
-If one want's to read rows in physical sequences, then one should instead use mi_scan() or mi_rrnd().
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-Inx is the index (key) number, which must be the same as currently selected.
-
-mi_rfirst() works by setting the current position mip->lastpos to HA_OFFSET_ERROR (undefined) then calling mi_rnext().
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_rfirst( mip, buffer, keynum);
-====================
-#.# mi_rkey()
-
-int mi_rkey(MI_INFO *mip, byte *buf, int inx, const byte *key, uint key_len, enum ha_rkey_function search_flag)
-
-#.#.1 Description
-
-Reads the next row after the last row read, using the current index.
-If one want's to read rows in physical sequences, then one should instead use mi_scan() or mi_rrnd().
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-Inx is the index (key) number, which must be the same as currently selected.
-
-If (mip->lastpos) is HA_OFFSET_ERROR (undefined) then mi_rnext() gives the first row.
-If you specify a different index number than the last read used, you will get an error.
-If the last (current) row has been changed since we read it, mi_rnext() will reposition from the position where that row WAS, not where it is now. (This behaviour is similar to CISAM and better than used in Codebase.)
-
-mi_extra(HA_EXTRA_KEYREAD) can be called first, to cause mi_rkey to read the key but not the record. Then call mi_extra(HA_EXTRA_NO_KEYREAD) to resume normal behaviour.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_rnext( mip, buffer, keynum );
-====================
-#.# mi_rlast()
-
-int mi_rlast(MI_INFO *mip , byte *buf, int inx)
-
-#.#.1 Description
-
-Reads the last row in the MyISAM file according to the specified index.
-If one want's to read rows in physical sequences, then one should instead use mi_scan() or mi_rrnd().
-mip is an MI_INFO pointer to the open handle.
-buf is a pointer to the record buffer that will contain the row.
-Inx is the index (key) number, which must be the same as currently selected.
-
-mi_rlast() works by setting the current position (mip->lastpos) to HA_OFFSET_ERROR (undefined) then calling mi_rprev().
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_rlast( mip, buffer, keynum);
-====================
-#.# mi_rnext()
-
-int mi_rnext(MI_INFO *mip , byte *buf, int inx )
-
-#.#.1 Description
-
-Reads the next row after the last row read, using the current index.
-If one want's to read rows in physical sequences, then one should instead use mi_scan() or mi_rrnd().
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-Inx is the index (key) number, which must be the same as currently selected.
-
-If (mip->lastpos) is HA_OFFSET_ERROR (undefined) then mi_rnext() gives the first row.
-If you specify a different index number than the last read used, you will get an error.
-If the last (current) row has been changed since we read it, mi_rnext() will reposition from the position where that row WAS, not where it is now. (This behaviour is similar to CISAM and better than used in Codebase.)
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_rnext( mip, buffer, keynum );
-====================
-#.# mi_rrnd()
-
-int mi_rrnd( MI_INFO *mip , byte *buf, my_off_t filepos )
-
-#.#.1 Description
-
-Reads a row based on physical position.
-
-Position can be calculated from record number only when fixed record lengths are used:
-position = mip->s.pack.header_length + recnum * mip->s->base.reclength.
-If filepos= HA_OFFSET_ERROR then it reads the next row.
-And if (mip->lastpos == HA_OFFSET_ERROR) it reads the first row.
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-filepos is the byte position in the file of the required record.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_RECORD_DELETED
-A deleted record was read.
-HA_ERR_END_OF_FILE
-End of file.
-
-#.#.4 Examples
-
-error = mi_rrnd( mip, buffer, mip->nextpos );
-====================
-#.# mi_rprev()
-
-int mi_rprev(MI_INFO *mip , byte *buf, int inx)
-
-#.#.1 Description
-
-Reads the row previous to the last row read, using the current index.
-If one wants to read rows in physical sequences, then one should instead use mi_scan() or mi_rrnd().
-
-If (mip->lastpos) is HA_OFFSET_ERROR (undefined) then mi_rnext() gives the last row in the index.
-If you specify a different index number than the last read used, you will get an error.
-If the last (current) row has been changed since we read it, mi_rprev() will reposition from the position where that row WAS, not where it is now. This behaviour is similar to CISAM and better than used in Codebase.
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-Inx is the index (key) number, which must be the same as currently selected.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_rprev( mip, buffer, keynum );
-====================
-#.# mi_rsame()
-
-int mi_rsame(MI_INFO *mip, byte *buf, int inx)
-
-#.#.1 Description
-
-Reads the current row to get its latest contents. This is useful to refresh the record buffer in case someone else has changed it.
-If inx is negative it reads by position. If inx is >= 0 it reads by key.
-With mi_rsame() one can switch to use any other index for the current row. This is good if you have a user application that lets the user do 'read-next' on a row. In this case, if the user want's to start scanning on another index, one simply has to do a mi_rsame() on the new index to activate this.
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-inx is the index (key) number, or a negative number to select read by position not index. Maybe the negative number has to be (-1) to achieve this behaviour.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_WRONG_INDEX
-an incorrect index number was supplied
-HA_ERR_KEY_NOT_FOUND
-info->lastpos was not defined, or the record was already deleted.
-
-#.#.4 Examples
-
-error = mi_rsame( m5mip, rec_ptr, keynum );
-====================
-#.# mi_scan()
-
-int mi_scan(MI_INFO *mip, byte *buf)
-
-#.#.1 Description
-
-Reads the next row by physical position.
-
-Deleted rows are bypassed.
-mi_scan() uses a function pointer "read_rnd" that uses either lower level static or dynamic read functions, positioning from mip->nextpos. Read_rnd is defined in mi_open() depending if the table is Static (read*static - see mi_statrec.c), Compressed (read*pack - see mi_packrec.c), or Space packed or Blobs (read*dynamic - see mi_dynrec.c).
-See also mi_scan_init() which initialises ready to mi_scan() through the whole table.
-
-mip is an MI_INFO pointer to the open handle.
-buf is the record buffer that will contain the row.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_END_OF_FILE
-End of file
-Otherwise one has probably got a fatal error like HA_ERR_CRASHED or some I-O related error from the Operating System.
-
-#.#.4 Examples
-
-error = mi_scan( mip, recbuff );
-====================
-#.# mi_scan_init()
-
-int mi_scan_init(MI_INFO *mip[SB1])
-
-#.#.1 Description
-
-Initialises ready to mi_scan() through all rows.
-
-mip is an MI_INFO pointer to the open handle.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-====================
-#.# mi_status()
-
-int mi_status(MI_INFO *mip, MI_ISAMINFO *x, uint flag)
-
-#.#.1 Description
-
-Gets information about the table.
-It is used to get/fill the MI_ISAMINFO struct with statistics data about the MySQL server. One can get information of the number of active rows, delete rows, file lengths...
-
-mip is an MI_INFO pointer to the open handle.
-flag is one of the following:
-HA_STATUS_POS Return position
-HA_STATUS_NO_LOCK Don't use external lock
-HA_STATUS_TIME Return update time
-HA_STATUS_CONST Return constants value
-HA_STATUS_VARIABLE
-HA_STATUS_ERRKEY
-HA_STATUS_AUTO
-
-#.#.2 Return values
-
-Zero.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-====================
-#.# mi_update()
-
-int mi_update( MI_INFO *mip, const byte *oldbuf, byte *newbuf)
-
-#.#.1 Description
-
-Updates the contents of the current record.
-By default you must supply an oldbuf record buffer with the current record contents. This is compared with the file as a guard in case someone else has changed the record in the meantime. *
-
-mip is an MI_INFO pointer to the open handle.
-oldbuf is the record buffer that contains the current record contents.
-newbuf is the record buffer that contains the new record contents.
-
-*Sometimes you might want to force an update without checking whether another user has changed the record since you last read it. This is somewhat dangerous, so it should ideally not be used. That can be accomplished by wrapping the mi_update() call in two calls to mi_extra(), using these functions:
-HA_EXTRA_NO_READCHECK=5 No readcheck on update
-HA_EXTRA_READCHECK=6 Use readcheck (def)
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-EACCES
-The file was opened for read-only access.
-HA_ERR_RECORD_CHANGED
- When mi_update() read the current record contents before updating, it differed from oldbuf.
-HA_ERR_CRASHED
-Key could not be found ??
-HA_ERR_FOUND_DUPP_KEY
-HA_ERR_RECORD_FILE_FULL
-
-#.#.4 Examples
-
-error = mi_update( mip, oldbuf, newbuf );
-====================
-#.# mi_write()
-
-int mi_write( MI_INFO *mip, byte *record)
-
-#.#.1 Description
-
-Writes a row to a MyISAM table.
-
-mip is an MI_INFO pointer to the open handle.
-The record contents are supplied in buf record buffer.
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-HA_ERR_FOUND_DUPP_KEY
-A record already existed with a unique key same as this new record.
-HA_ERR_RECORD_FILE_FULL
-The error is given if you hit a system limit or if you try to create more rows in a table that you reserverd room for with mi_create().
-ENOSPC
-The disk is full.
-EACCES
-The file was opened for read-only access.
-
-#.#.4 Examples
-
-error = mi_write( m5mip, recbuf );
-====================
-#.# my_end()
-
-void my_end(int infoflag)
-
-#.#.1 Description
-
-Shows debugging information about open MyISAM handles.
-my_end() exists primarily for MyISAM debugging.
-It would not normally be used in a production environment.
-It can give a nice summary of how you have used my_xxx() functions.
-It can be used to check that you have closed all files that you have opened.
-
-infoflag is the list function and can be:
-MY_CHECK_ERROR List which MyISAM handles are open.
-MY_GIVE_INFO Show runtime information.
-
-#.#.2 Return values
-
-Void
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-my_end(MY_CHECK_ERROR | MY_GIVE_INFO);
-====================
-#.# my_init()
-
-void my_init( void )
-
-#.#.1 Description
-
-Performs MyISAM initialisation for program startup, particularly if using threads.
-
-If using threads, be sure to call my_init() at start of program. (CFS does this in XPOPEN.) It is also safe to call my_init() when not using threads.
-
-#.#.2 Return values
-
-void
-Sometimes my_errno might be meaningful if a warning is generated during debugging.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-my_init();
-====================
-#.# init_key_cache()
-
-int init_key_cache( long int use_mem, (uint) reserve_mem;
-
-#.#.1 Description
-
-Starts and controls caching of keys. Call init_key_cache() to reserve memory for key caching and to start the caching. (CFS does this in XPOPEN if MYCACHE is defined (regular size), or MYCACHELARGE or MYCACHESMALL.)
-
-Provide use_mem the number of bytes of memory to use for key caching by this process.
-reserve_mem should be 0. This is just for very old systems with very little memory.
-
-#.#.2 Return values
-
-The number of 1kb memory blocks now allocated to key caching. Zero if key caching cannot be started (check my_errno), or key caching was already active.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-Blocks = init_key_cache( 65536L, IO_SIZE*4*10 );
-====================
-#.# _mi_make_key()
-
-uint _mi_make_key( MI_INFO *mip, uint keynr, uchar *key, const char *record, my_off_t filepos)
-
-#.#.1 Description
-
-Construct a key string for the given index, from the provided record buffer.
-??? When packed records are used ...
-This is an internal function, not for use by applications. Monty says: "This can't be used to create an external key for an application from your record."
-See mi_make_application_key() for a similar function that is useable by applications.
-
-The parameters are:
-A MI_INFO pointer mip.
-The index number keynr.
-The buffer to contain the formatted key string key.
-The record buffer record.
-??? A file position filepos or zero.
-
-#.#.2 Return values
-
-The byte length of the created key string.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-uint new_length=_mi_make_key(info,i,new_key,newrec,pos);
-====================
-#.# _mi_print_key()
-
-void _mi_print_key(FILE *stream, MI_KEYSEG *keyseg, const uchar *key, uint length)
-
-#.#.1 Description
-
-Prints a key in a user understandable format.
-This is an internal function for debugging, not for use by applications.
-??? Not yet fully documented. I just include it here so that I know it exists.
-
-#.#.2 Return values
-
-A readable print of the key contents goes to the specified output.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-
-_mi_print_key(stdout,share->keyinfo[info->errkey].seg,info->lastkey, USE_WHOLE_KEY);
-====================
-APPENDIX B Choosing a table type
-(excerpt from manual.txt in MySQL 3.23.8-alpha)
-
-With MySQL you can currently (version 3.23.5) choose between four usable table formats from a speed point of view.
-
-Static (Fixed-length) table characteristics
-* This is the default format. It's used when the table contains no `VARCHAR', `BLOB' or `TEXT' columns.
-* All `CHAR', `NUMERIC' and `DECIMAL' columns are space-padded to the column width.
-* Very quick.
-* Easy to cache.
-* Easy to reconstruct after a crash, because records are located in fixed positions.
-* Doesn't have to be reorganized (with `myisamchk') unless a huge number of records are deleted and you want to return free disk space to the operating system.
-* Usually requires more disk space than dynamic tables.
-
-Dynamic table characteristics
-* This format is used if the table contains any `VARCHAR', `BLOB' or `TEXT' columns.
-* All string columns are dynamic (except those with a length less than 4).
-* Each record is preceded by a bitmap indicating which columns are empty (`''') for string columns, or zero for numeric columns (this isn't the same as columns containing `NULL' values). If a string column has a length of zero after removal of trailing spaces, or a numeric column has a value of zero, it is marked in the bit map and not saved to disk. Non-empty strings are saved as a length byte plus the string contents.
-* Usually takes much less disk space than fixed-length tables.
-* Each record uses only as much space as is required. If a record becomes larger, it is split into as many pieces as required. This results in record fragmentation.
-* If you update a row with information that extends the row length, the row will be fragmented. In this case, you may have to run `myisamchk -r' from time to time to get better performance. Use `myisamchk -ei tbl_name' for some statistics.
-* Not as easy to reconstruct after a crash, because a record may be fragmented into many pieces and a link (fragment) may be missing.
-* The expected row length for dynamic sized records is:
-3
-+ (number of columns + 7) / 8
-+ (number of char columns)
-+ packed size of numeric columns
-+ length of strings
-+ (number of NULL columns + 7) / 8
-There is a penalty of 6 bytes for each link. A dynamic record is linked whenever an update causes an enlargement of the record.
-Each new link will be at least 20 bytes, so the next enlargement will probably go in the same link. If not, there will be another link. You may check how many links there are with `myisamchk -ed'. All links may be removed with `myisamchk -r'.
-
-Compressed table characteristics
-* A read-only table made with the `myisampack' utility. All customers with extended *MySQL* email support are entitled to a copy of `myisampack' for their internal usage.
-* The uncompress code exists in all *MySQL* distributions so that even customers who don't have `myisampack' can read tables that were compressed with `myisampack'
-* Takes very little disk space. Minimises disk usage.
-* Each record is compressed separately (very little access overhead). The header for a record is fixed (1-3 bytes) depending on the biggest record in the table. Each column is compressed differently. Some of the compression types are:
-- There is usually a different Huffman table for each column.
-- Suffix space compression.
-- Prefix space compression.
-- Numbers with value `0' are stored using 1 bit.
-- If values in an integer column have a small range, the column is stored using the smallest possible type. For example, a `BIGINT' column (8 bytes) may be stored as a `TINYINT' column (1 byte) if all values are in the range `0' to `255'.
-- If a column has only a small set of possible values, the column type is converted to `ENUM'.
-- A column may use a combination of the above compressions.
-* Can handle fixed or dynamic length records, but not `BLOB' or `TEXT' columns.
-* Can be uncompressed with `myisamchk'.
-
-*MySQL* can support different index types, but the normal type is ISAM.
-This is a B-tree index and you can roughly calculate the size for the index file as `(key_length+4)*0.67', summed over all keys. (This is for the worst case when all keys are inserted in sorted order.)
-
-String indexes are space compressed. If the first index part is a string, it will also be prefix compressed.
-Space compression makes the index file smaller if the string column has a lot of trailing space or is a `VARCHAR' column that is not always used to the full length.
-Prefix compression helps if there are many strings with an identical prefix.
-
-In memory table characteristics
-HEAP tables only exists in memory so they are lost if `mysqld' is taken down or crashes. But since they are *very* fast they are usefull as anyway.
-
-The *MySQL* internal HEAP tables uses 100% dynamic hashing without overflow areas and don't have problems with delete.
-
-You can only access things by equality using a index (usually by the `=' operator) whith a heap table.
-The downside with HEAPS are:
- 1. You need enough extra memory for all HEAP tables that you want to use at the same time.
- 2. You can't search on a part of a index.
- 3. You can't search for the next entry in order (that is to use the index to do a `ORDER BY').
-1. *MySQL* also cannot find out how approximately many rows there are between two values. This is used by the optimizer to chose which index to use. But on the other hand no disk seeks are even needed.
-====================
-#.# mi_()
-
-#.#.1 Description
-
-#.#.2 Return values
-
-Zero if successful. Non-zero if an error occurred.
-
-#.#.3 Errors
-
-Nothing specific yet identified.
-
-#.#.4 Examples
-[SB1]int _mi_read_rnd_static_record(MI_INFO *info, byte *buf, my_off_t filepos,
- my_bool skipp_deleted_blocks)
-int _mi_read_dynamic_record(MI_INFO *info, my_off_t filepos, byte *buf)
-
-Printed on 17/03/00
-
-C-7
diff --git a/Docs/manual.texi b/Docs/manual.texi
index 417b4ebf8a0..36090a4d6b9 100644
--- a/Docs/manual.texi
+++ b/Docs/manual.texi
@@ -42425,8 +42425,8 @@ of connections in a short time).
Don't free the key cache on @code{FLUSH TABLES} as this will cause problems
with temporary tables.
@item
-Fixed problem in Innobase with with other character sets than latin1 and
-alarms on Solaris.
+Fixed problem in Innobase with with other character sets than latin1,
+alarms on Solaris and many columns.
@item
Fixed a core-dump bug when using very complex query involving
@code{DISTINCT} and summary functions.
diff --git a/client/Attic/libmysql.c b/client/Attic/libmysql.c
deleted file mode 100644
index 4f5e138fd53..00000000000
--- a/client/Attic/libmysql.c
+++ /dev/null
@@ -1,2392 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#define DONT_USE_RAID
-#if defined(__WIN32__) || defined(WIN32)
-#include <winsock.h>
-#include <odbcinst.h>
-#endif
-#include <global.h>
-#include <my_sys.h>
-#include <mysys_err.h>
-#include <m_string.h>
-#include <m_ctype.h>
-#include "mysql.h"
-#include "mysql_version.h"
-#include "mysqld_error.h"
-#include "errmsg.h"
-#include <violite.h>
-#include <sys/stat.h>
-#include <signal.h>
-#ifdef HAVE_PWD_H
-#include <pwd.h>
-#endif
-#if !defined(MSDOS) && !defined(__WIN32__)
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <netdb.h>
-#ifdef HAVE_SELECT_H
-# include <select.h>
-#endif
-#ifdef HAVE_SYS_SELECT_H
-#include <sys/select.h>
-#endif
-#endif
-#ifdef HAVE_SYS_UN_H
-# include <sys/un.h>
-#endif
-#if defined(THREAD) && !defined(__WIN32__)
-#include <my_pthread.h> /* because of signal() */
-#endif
-#ifndef INADDR_NONE
-#define INADDR_NONE -1
-#endif
-
-static my_bool mysql_client_init=0;
-static MYSQL *current_mysql;
-uint mysql_port=0;
-my_string mysql_unix_port=0;
-
-#define CLIENT_CAPABILITIES (CLIENT_LONG_PASSWORD | CLIENT_LONG_FLAG | CLIENT_LOCAL_FILES)
-
-#if defined(MSDOS) || defined(__WIN32__)
-#define ERRNO WSAGetLastError()
-#define perror(A)
-#else
-#include <sys/errno.h>
-#define ERRNO errno
-#define SOCKET_ERROR -1
-#define closesocket(A) close(A)
-#endif
-
-static void mysql_once_init(void);
-static MYSQL_DATA *read_rows (MYSQL *mysql,MYSQL_FIELD *fields,
- uint field_count);
-static int read_one_row(MYSQL *mysql,uint fields,MYSQL_ROW row,
- ulong *lengths);
-static void end_server(MYSQL *mysql);
-static void remember_connection(MYSQL *mysql);
-static void read_user_name(char *name);
-static void append_wild(char *to,char *end,const char *wild);
-static my_bool mysql_reconnect(MYSQL *mysql);
-static int send_file_to_server(MYSQL *mysql,const char *filename);
-static sig_handler pipe_sig_handler(int sig);
-
-/*
- Let the user specify that we don't want SIGPIPE; This doesn't however work
- with threaded applications as we can have multiple read in progress.
-*/
-
-#if !defined(__WIN32__) && defined(SIGPIPE) && !defined(THREAD)
-#define init_sigpipe_variables sig_return old_signal_handler;
-#define set_sigpipe(mysql) if ((mysql)->client_flag & CLIENT_IGNORE_SIGPIPE) old_signal_handler=signal(SIGPIPE,pipe_sig_handler)
-#define reset_sigpipe(mysql) if ((mysql)->client_flag & CLIENT_IGNORE_SIGPIPE) signal(SIGPIPE,old_signal_handler);
-#else
-#define init_sigpipe_variables
-#define set_sigpipe(mysql)
-#define reset_sigpipe(mysql)
-#endif
-
-/****************************************************************************
-* A modified version of connect(). connect2() allows you to specify
-* a timeout value, in seconds, that we should wait until we
-* derermine we can't connect to a particular host. If timeout is 0,
-* connect2() will behave exactly like connect().
-*
-* Base version coded by Steve Bernacki, Jr. <steve@navinet.net>
-*****************************************************************************/
-
-static int connect2(File s, const struct sockaddr *name, uint namelen, uint to)
-{
-#if defined(__WIN32__)
- return connect(s, (struct sockaddr*) name, namelen);
-#else
- int flags, res, s_err;
- size_socket s_err_size = sizeof(uint);
- fd_set sfds;
- struct timeval tv;
-
- /* If they passed us a timeout of zero, we should behave
- * exactly like the normal connect() call does.
- */
-
- if (to == 0)
- return connect(s, (struct sockaddr*) name, namelen);
-
- flags = fcntl(s, F_GETFL, 0); /* Set socket to not block */
-#ifdef O_NONBLOCK
- fcntl(s, F_SETFL, flags | O_NONBLOCK); /* and save the flags.. */
-#endif
-
- res = connect(s, (struct sockaddr*) name, namelen);
- s_err = errno; /* Save the error... */
- fcntl(s, F_SETFL, flags);
- if ((res != 0) && (s_err != EINPROGRESS))
- {
- errno = s_err; /* Restore it */
- return(-1);
- }
- if (res == 0) /* Connected quickly! */
- return(0);
-
- /* Otherwise, our connection is "in progress." We can use
- * the select() call to wait up to a specified period of time
- * for the connection to suceed. If select() returns 0
- * (after waiting howevermany seconds), our socket never became
- * writable (host is probably unreachable.) Otherwise, if
- * select() returns 1, then one of two conditions exist:
- *
- * 1. An error occured. We use getsockopt() to check for this.
- * 2. The connection was set up sucessfully: getsockopt() will
- * return 0 as an error.
- *
- * Thanks goes to Andrew Gierth <andrew@erlenstar.demon.co.uk>
- * who posted this method of timing out a connect() in
- * comp.unix.programmer on August 15th, 1997.
- */
-
- FD_ZERO(&sfds);
- FD_SET(s, &sfds);
- tv.tv_sec = (long) to;
- tv.tv_usec = 0;
- res = select(s+1, NULL, &sfds, NULL, &tv);
- if (res <= 0) /* Never became writable */
- return(-1);
-
- /* select() returned something more interesting than zero, let's
- * see if we have any errors. If the next two statements pass,
- * we've got an open socket!
- */
-
- s_err=0;
- if (getsockopt(s, SOL_SOCKET, SO_ERROR, (char*) &s_err, &s_err_size) != 0)
- return(-1);
-
- if (s_err)
- { /* getsockopt() could suceed */
- errno = s_err;
- return(-1); /* but return an error... */
- }
- return(0); /* It's all good! */
-#endif
-}
-
-/*
-** Create a named pipe connection
-*/
-
-#ifdef __WIN32__
-
-HANDLE create_named_pipe(NET *net, uint connect_timeout, char **arg_host,
- char **arg_unix_socket)
-{
- HANDLE hPipe=INVALID_HANDLE_VALUE;
- char szPipeName [ 257 ];
- DWORD dwMode;
- int i;
- my_bool testing_named_pipes=0;
- char *host= *arg_host, *unix_socket= *arg_unix_socket;
-
- if ( ! unix_socket || (unix_socket)[0] == 0x00)
- unix_socket = mysql_unix_port;
- if (!host || !strcmp(host,LOCAL_HOST))
- host=LOCAL_HOST_NAMEDPIPE;
-
- sprintf( szPipeName, "\\\\%s\\pipe\\%s", host, unix_socket);
- DBUG_PRINT("info",("Server name: '%s'. Named Pipe: %s",
- host, unix_socket));
-
- for (i=0 ; i < 100 ; i++) /* Don't retry forever */
- {
- if ((hPipe = CreateFile(szPipeName,
- GENERIC_READ | GENERIC_WRITE,
- 0,
- NULL,
- OPEN_EXISTING,
- 0,
- NULL )) != INVALID_HANDLE_VALUE)
- break;
- if (GetLastError() != ERROR_PIPE_BUSY)
- {
- net->last_errno=CR_NAMEDPIPEOPEN_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- /* wait for for an other instance */
- if (! WaitNamedPipe(szPipeName, connect_timeout*1000) )
- {
- net->last_errno=CR_NAMEDPIPEWAIT_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- }
- if (hPipe == INVALID_HANDLE_VALUE)
- {
- net->last_errno=CR_NAMEDPIPEOPEN_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- dwMode = PIPE_READMODE_BYTE | PIPE_WAIT;
- if ( !SetNamedPipeHandleState(hPipe, &dwMode, NULL, NULL) )
- {
- CloseHandle( hPipe );
- net->last_errno=CR_NAMEDPIPESETSTATE_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- *arg_host=host ; *arg_unix_socket=unix_socket; /* connect arg */
- return (hPipe);
-}
-#endif
-
-
-/*****************************************************************************
-** read a packet from server. Give error message if socket was down
-** or packet is an error message
-*****************************************************************************/
-
-static uint
-net_safe_read(MYSQL *mysql)
-{
- NET *net= &mysql->net;
- uint len=0;
- init_sigpipe_variables
-
- /* Don't give sigpipe errors if the client doesn't want them */
- set_sigpipe(mysql);
- if (net->vio != 0)
- len=my_net_read(net);
- reset_sigpipe(mysql);
-
- if (len == packet_error || len == 0)
- {
- DBUG_PRINT("error",("Wrong connection or packet. fd: %s len: %d",
- vio_description(net->vio),len));
- end_server(mysql);
- net->last_errno=CR_SERVER_LOST;
- strmov(net->last_error,ER(net->last_errno));
- return(packet_error);
- }
- if (net->read_pos[0] == 255)
- {
- if (len > 3)
- {
- char *pos=(char*) net->read_pos+1;
- if (mysql->protocol_version > 9)
- { /* New client protocol */
- net->last_errno=uint2korr(pos);
- pos+=2;
- len-=2;
- }
- else
- {
- net->last_errno=CR_UNKNOWN_ERROR;
- len--;
- }
- (void) strmake(net->last_error,(char*) pos,
- min(len,sizeof(net->last_error)-1));
- }
- else
- {
- net->last_errno=CR_UNKNOWN_ERROR;
- (void) strmov(net->last_error,ER(net->last_errno));
- }
- DBUG_PRINT("error",("Got error: %d (%s)", net->last_errno,
- net->last_error));
- return(packet_error);
- }
- return len;
-}
-
-
-/* Get the length of next field. Change parameter to point at fieldstart */
-static ulong
-net_field_length(uchar **packet)
-{
- reg1 uchar *pos= *packet;
- if (*pos < 251)
- {
- (*packet)++;
- return (ulong) *pos;
- }
- if (*pos == 251)
- {
- (*packet)++;
- return NULL_LENGTH;
- }
- if (*pos == 252)
- {
- (*packet)+=3;
- return (ulong) uint2korr(pos+1);
- }
- if (*pos == 253)
- {
- (*packet)+=4;
- return (ulong) uint3korr(pos+1);
- }
- (*packet)+=9; /* Must be 254 when here */
- return (ulong) uint4korr(pos+1);
-}
-
-/* Same as above, but returns ulonglong values */
-
-static my_ulonglong
-net_field_length_ll(uchar **packet)
-{
- reg1 uchar *pos= *packet;
- if (*pos < 251)
- {
- (*packet)++;
- return (my_ulonglong) *pos;
- }
- if (*pos == 251)
- {
- (*packet)++;
- return (my_ulonglong) NULL_LENGTH;
- }
- if (*pos == 252)
- {
- (*packet)+=3;
- return (my_ulonglong) uint2korr(pos+1);
- }
- if (*pos == 253)
- {
- (*packet)+=4;
- return (my_ulonglong) uint3korr(pos+1);
- }
- (*packet)+=9; /* Must be 254 when here */
-#ifdef NO_CLIENT_LONGLONG
- return (my_ulonglong) uint4korr(pos+1);
-#else
- return (my_ulonglong) uint8korr(pos+1);
-#endif
-}
-
-
-static void free_rows(MYSQL_DATA *cur)
-{
- if (cur)
- {
- free_root(&cur->alloc);
- my_free((gptr) cur,MYF(0));
- }
-}
-
-
-static int
-simple_command(MYSQL *mysql,enum enum_server_command command, const char *arg,
- uint length, my_bool skipp_check)
-{
- NET *net= &mysql->net;
- int result= -1;
- init_sigpipe_variables
-
- /* Don't give sigpipe errors if the client doesn't want them */
- set_sigpipe(mysql);
- if (mysql->net.vio == 0)
- { /* Do reconnect if possible */
- if (mysql_reconnect(mysql))
- {
- net->last_errno=CR_SERVER_GONE_ERROR;
- strmov(net->last_error,ER(net->last_errno));
- goto end;
- }
- }
- if (mysql->status != MYSQL_STATUS_READY)
- {
- strmov(net->last_error,ER(mysql->net.last_errno=CR_COMMANDS_OUT_OF_SYNC));
- goto end;
- }
-
- mysql->net.last_error[0]=0;
- mysql->net.last_errno=0;
- mysql->info=0;
- mysql->affected_rows= ~(my_ulonglong) 0;
- remember_connection(mysql);
- net_clear(net); /* Clear receive buffer */
- if (!arg)
- arg="";
-
- if (net_write_command(net,(uchar) command,arg,
- length ? length :strlen(arg)))
- {
- DBUG_PRINT("error",("Can't send command to server. Error: %d",errno));
- end_server(mysql);
- if (mysql_reconnect(mysql) ||
- net_write_command(net,(uchar) command,arg,
- length ? length :strlen(arg)))
- {
- net->last_errno=CR_SERVER_GONE_ERROR;
- strmov(net->last_error,ER(net->last_errno));
- reset_sigpipe(mysql);
- goto end;
- }
- }
- result=0;
- if (!skipp_check)
- result= ((mysql->packet_length=net_safe_read(mysql)) == packet_error ?
- -1 : 0);
- end:
- reset_sigpipe(mysql);
- return result;
-}
-
-
-static void free_old_query(MYSQL *mysql)
-{
- DBUG_ENTER("free_old_query");
- if (mysql->fields)
- free_root(&mysql->field_alloc);
- init_alloc_root(&mysql->field_alloc,8192); /* Assume rowlength < 8192 */
- mysql->fields=0;
- mysql->field_count=0; /* For API */
- DBUG_VOID_RETURN;
-}
-
-#ifdef HAVE_GETPWUID
-struct passwd *getpwuid(uid_t);
-char* getlogin(void);
-#endif
-
-#if !defined(MSDOS) && ! defined(VMS) && !defined(__WIN32__)
-static void read_user_name(char *name)
-{
- DBUG_ENTER("read_user_name");
- if (geteuid() == 0)
- (void) strmov(name,"root"); /* allow use of surun */
- else
- {
-#ifdef HAVE_GETPWUID
- struct passwd *skr;
- const char *str;
-/*#ifdef __cplusplus
- extern "C" struct passwd *getpwuid(uid_t);
- extern "C" { char* getlogin(void); }
-#else
- char * getlogin();
- struct passwd *getpwuid(uid_t);
-#endif
-*/
- if ((str=getlogin()) == NULL)
- {
- if ((skr=getpwuid(geteuid())) != NULL)
- str=skr->pw_name;
- else if (!(str=getenv("USER")) && !(str=getenv("LOGNAME")) &&
- !(str=getenv("LOGIN")))
- str="UNKNOWN_USER";
- }
- (void) strmake(name,str,USERNAME_LENGTH);
-#elif HAVE_CUSERID
- (void) cuserid(name);
-#else
- strmov(name,"UNKNOWN_USER");
-#endif
- }
- DBUG_VOID_RETURN;
-}
-
-#else /* If MSDOS || VMS */
-
-static void read_user_name(char *name)
-{
- char *str=getenv("USER");
- strmov(name,str ? str : "ODBC"); /* ODBC will send user variable */
-}
-
-#endif
-
-#ifdef __WIN32__
-static my_bool is_NT(void)
-{
- char *os=getenv("OS");
- return (os && !strcmp(os, "Windows_NT")) ? 1 : 0;
-}
-#endif
-
-/*
-** Expand wildcard to a sql string
-*/
-
-static void
-append_wild(char *to, char *end, const char *wild)
-{
- end-=5; /* Some extra */
- if (wild && wild[0])
- {
- to=strmov(to," like '");
- while (*wild && to < end)
- {
- if (*wild == '\\' || *wild == '\'')
- *to++='\\';
- *to++= *wild++;
- }
- if (*wild) /* Too small buffer */
- *to++='%'; /* Nicer this way */
- to[0]='\'';
- to[1]=0;
- }
-}
-
-
-
-/**************************************************************************
-** Init debugging if MYSQL_DEBUG environment variable is found
-**************************************************************************/
-
-void STDCALL
-mysql_debug(const char *debug)
-{
-#ifndef DBUG_OFF
- char *env;
- if (_db_on_)
- return; /* Already using debugging */
- if (debug)
- {
- DEBUGGER_ON;
- DBUG_PUSH(debug);
- }
- else if ((env = getenv("MYSQL_DEBUG")))
- {
- DEBUGGER_ON;
- DBUG_PUSH(env);
-#if !defined(_WINVER) && !defined(WINVER)
- puts("\n-------------------------------------------------------");
- puts("MYSQL_DEBUG found. libmysql started with the following:");
- puts(env);
- puts("-------------------------------------------------------\n");
-#else
- {
- char buff[80];
- strmov(strmov(buff,"libmysql: "),env);
- MessageBox((HWND) 0,"Debugging variable MYSQL_DEBUG used",buff,MB_OK);
- }
-#endif
- }
-#endif
-}
-
-
-/**************************************************************************
-** Store the server socket currently in use
-** Used by pipe_handler if error on socket interrupt
-**************************************************************************/
-
-static void
-remember_connection(MYSQL *mysql)
-{
- current_mysql = mysql;
-}
-
-/**************************************************************************
-** Close the server connection if we get a SIGPIPE
- ARGSUSED
-**************************************************************************/
-
-static sig_handler
-pipe_sig_handler(int sig __attribute__((unused)))
-{
- DBUG_PRINT("info",("Hit by signal %d",sig));
-#ifdef DONT_REMEMBER_SIGNAL
- (void) signal(SIGPIPE,pipe_sig_handler);
-#endif
-}
-
-
-/**************************************************************************
-** Shut down connection
-**************************************************************************/
-
-static void
-end_server(MYSQL *mysql)
-{
- DBUG_ENTER("end_server");
- if (mysql->net.vio != 0)
- {
- init_sigpipe_variables
- DBUG_PRINT("info",("Net: %s", vio_description(mysql->net.vio)));
- set_sigpipe(mysql);
- vio_delete(mysql->net.vio);
- reset_sigpipe(mysql);
- mysql->net.vio= 0; /* Marker */
- }
- net_end(&mysql->net);
- free_old_query(mysql);
- DBUG_VOID_RETURN;
-}
-
-
-void STDCALL
-mysql_free_result(MYSQL_RES *result)
-{
- DBUG_ENTER("mysql_free_result");
- DBUG_PRINT("enter",("mysql_res: %lx",result));
- if (result)
- {
- if (result->handle && result->handle->status == MYSQL_STATUS_USE_RESULT)
- {
- DBUG_PRINT("warning",("Not all rows in set were read; Ignoring rows"));
- for (;;)
- {
- uint pkt_len;
- if ((pkt_len=(uint) net_safe_read(result->handle)) == packet_error)
- break;
- if (pkt_len == 1 && result->handle->net.read_pos[0] == 254)
- break; /* End of data */
- }
- result->handle->status=MYSQL_STATUS_READY;
- }
- free_rows(result->data);
- if (result->fields)
- free_root(&result->field_alloc);
- if (result->row)
- my_free((gptr) result->row,MYF(0));
- my_free((gptr) result,MYF(0));
- }
- DBUG_VOID_RETURN;
-}
-
-
-/****************************************************************************
-** Get options from my.cnf
-****************************************************************************/
-
-static const char *default_options[]=
-{"port","socket","compress","password","pipe", "timeout", "user",
- "init-command", "host", "database", "debug", "return-found-rows",
-#ifdef HAVE_OPENSSL
- "ssl_key" ,"ssl_cert" ,"ssl_ca" ,"ssl_capath",
-#endif /* HAVE_OPENSSL */
- NullS
-};
-static TYPELIB option_types={array_elements(default_options)-1,(char*) "options",(char **) default_options};
-
-static void mysql_read_default_options(struct st_mysql_options *options,
- const char *filename,const char *group)
-{
- int argc;
- char *argv_buff[1],**argv;
- const char *groups[3];
- DBUG_ENTER("mysql_read_default_options");
- DBUG_PRINT("enter",("file: %s group: %s",filename,group ? group :"NULL"));
-
- argc=1; argv=argv_buff; argv_buff[0]= (char*) "client";
- groups[0]= (char*) "client"; groups[1]= (char*) group; groups[2]=0;
-
- load_defaults(filename, groups, &argc, &argv);
- if (argc != 1) /* If some default option */
- {
- char **option=argv;
- while (*++option)
- {
- /* DBUG_PRINT("info",("option: %s",option[0])); */
- if (option[0][0] == '-' && option[0][1] == '-')
- {
- char *end=strcend(*option,'=');
- char *opt_arg=0;
- if (*end)
- {
- opt_arg=end+1;
- *end=0; /* Remove '=' */
- }
- switch (find_type(*option+2,&option_types,2)) {
- case 1: /* port */
- if (opt_arg)
- options->port=atoi(opt_arg);
- break;
- case 2: /* socket */
- if (opt_arg)
- {
- my_free(options->unix_socket,MYF(MY_ALLOW_ZERO_PTR));
- options->unix_socket=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 3: /* compress */
- options->compress=1;
- break;
- case 4: /* password */
- if (opt_arg)
- {
- my_free(options->password,MYF(MY_ALLOW_ZERO_PTR));
- options->password=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 5: /* pipe */
- options->named_pipe=1; /* Force named pipe */
- break;
- case 6: /* timeout */
- if (opt_arg)
- options->connect_timeout=atoi(opt_arg);
- break;
- case 7: /* user */
- if (opt_arg)
- {
- my_free(options->user,MYF(MY_ALLOW_ZERO_PTR));
- options->user=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 8: /* init-command */
- if (opt_arg)
- {
- my_free(options->init_command,MYF(MY_ALLOW_ZERO_PTR));
- options->init_command=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 9: /* host */
- if (opt_arg)
- {
- my_free(options->host,MYF(MY_ALLOW_ZERO_PTR));
- options->host=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 10: /* database */
- if (opt_arg)
- {
- my_free(options->db,MYF(MY_ALLOW_ZERO_PTR));
- options->db=my_strdup(opt_arg,MYF(MY_WME));
- }
- break;
- case 11: /* debug */
- mysql_debug(opt_arg ? opt_arg : "d:t:o,/tmp/client.trace");
- break;
- case 12: /* return-found-rows */
- options->client_flag|=CLIENT_FOUND_ROWS;
- break;
-#ifdef HAVE_OPENSSL
- case 13: /* ssl_key */
- my_free(options->ssl_key, MYF(MY_ALLOW_ZERO_PTR));
- options->ssl_key = my_strdup(opt_arg, MYF(MY_WME));
- break;
- case 14: /* ssl_cert */
- my_free(options->ssl_cert, MYF(MY_ALLOW_ZERO_PTR));
- options->ssl_cert = my_strdup(opt_arg, MYF(MY_WME));
- break;
- case 15: /* ssl_ca */
- my_free(options->ssl_ca, MYF(MY_ALLOW_ZERO_PTR));
- options->ssl_ca = my_strdup(opt_arg, MYF(MY_WME));
- break;
- case 16: /* ssl_capath */
- my_free(options->ssl_capath, MYF(MY_ALLOW_ZERO_PTR));
- options->ssl_capath = my_strdup(opt_arg, MYF(MY_WME));
- break;
-#endif /* HAVE_OPENSSL */
- default:
- DBUG_PRINT("warning",("unknown option: %s",option[0]));
- }
- }
- }
- }
- free_defaults(argv);
- DBUG_VOID_RETURN;
-}
-
-
-/***************************************************************************
-** Change field rows to field structs
-***************************************************************************/
-
-static MYSQL_FIELD *
-unpack_fields(MYSQL_DATA *data,MEM_ROOT *alloc,uint fields,
- my_bool default_value, my_bool long_flag_protocol)
-{
- MYSQL_ROWS *row;
- MYSQL_FIELD *field,*result;
- DBUG_ENTER("unpack_fields");
-
- field=result=(MYSQL_FIELD*) alloc_root(alloc,sizeof(MYSQL_FIELD)*fields);
- if (!result)
- DBUG_RETURN(0);
-
- for (row=data->data; row ; row = row->next,field++)
- {
- field->table= strdup_root(alloc,(char*) row->data[0]);
- field->name= strdup_root(alloc,(char*) row->data[1]);
- field->length= (uint) uint3korr(row->data[2]);
- field->type= (enum enum_field_types) (uchar) row->data[3][0];
- if (long_flag_protocol)
- {
- field->flags= uint2korr(row->data[4]);
- field->decimals=(uint) (uchar) row->data[4][2];
- }
- else
- {
- field->flags= (uint) (uchar) row->data[4][0];
- field->decimals=(uint) (uchar) row->data[4][1];
- }
- if (default_value && row->data[5])
- field->def=strdup_root(alloc,(char*) row->data[5]);
- else
- field->def=0;
- field->max_length= 0;
- }
- free_rows(data); /* Free old data */
- DBUG_RETURN(result);
-}
-
-
-/* Read all rows (fields or data) from server */
-
-static MYSQL_DATA *read_rows(MYSQL *mysql,MYSQL_FIELD *mysql_fields,
- uint fields)
-{
- uint field,pkt_len;
- ulong len;
- uchar *cp;
- char *to;
- MYSQL_DATA *result;
- MYSQL_ROWS **prev_ptr,*cur;
- NET *net = &mysql->net;
- DBUG_ENTER("read_rows");
-
- if ((pkt_len=(uint) net_safe_read(mysql)) == packet_error)
- DBUG_RETURN(0);
- if (!(result=(MYSQL_DATA*) my_malloc(sizeof(MYSQL_DATA),
- MYF(MY_WME | MY_ZEROFILL))))
- {
- net->last_errno=CR_OUT_OF_MEMORY;
- strmov(net->last_error,ER(net->last_errno));
- DBUG_RETURN(0);
- }
- init_alloc_root(&result->alloc,8192); /* Assume rowlength < 8192 */
- result->alloc.min_malloc=sizeof(MYSQL_ROWS);
- prev_ptr= &result->data;
- result->rows=0;
- result->fields=fields;
-
- while (*(cp=net->read_pos) != 254 || pkt_len != 1)
- {
- result->rows++;
- if (!(cur= (MYSQL_ROWS*) alloc_root(&result->alloc,
- sizeof(MYSQL_ROWS))) ||
- !(cur->data= ((MYSQL_ROW)
- alloc_root(&result->alloc,
- (fields+1)*sizeof(char *)+pkt_len))))
- {
- free_rows(result);
- net->last_errno=CR_OUT_OF_MEMORY;
- strmov(net->last_error,ER(net->last_errno));
- DBUG_RETURN(0);
- }
- *prev_ptr=cur;
- prev_ptr= &cur->next;
- to= (char*) (cur->data+fields+1);
- for (field=0 ; field < fields ; field++)
- {
- if ((len=(ulong) net_field_length(&cp)) == NULL_LENGTH)
- { /* null field */
- cur->data[field] = 0;
- }
- else
- {
- cur->data[field] = to;
- memcpy(to,(char*) cp,len); to[len]=0;
- to+=len+1;
- cp+=len;
- if (mysql_fields)
- {
- if (mysql_fields[field].max_length < len)
- mysql_fields[field].max_length=len;
- }
- }
- }
- cur->data[field]=to; /* End of last field */
- if ((pkt_len=net_safe_read(mysql)) == packet_error)
- {
- free_rows(result);
- DBUG_RETURN(0);
- }
- }
- *prev_ptr=0; /* last pointer is null */
- DBUG_PRINT("exit",("Got %d rows",result->rows));
- DBUG_RETURN(result);
-}
-
-
-/*
-** Read one row. Uses packet buffer as storage for fields.
-** When next packet is read, the previous field values are destroyed
-*/
-
-
-static int
-read_one_row(MYSQL *mysql,uint fields,MYSQL_ROW row, ulong *lengths)
-{
- uint field;
- ulong pkt_len,len;
- uchar *pos,*prev_pos;
-
- if ((pkt_len=(uint) net_safe_read(mysql)) == packet_error)
- return -1;
- if (pkt_len == 1 && mysql->net.read_pos[0] == 254)
- return 1; /* End of data */
- prev_pos= 0; /* allowed to write at packet[-1] */
- pos=mysql->net.read_pos;
- for (field=0 ; field < fields ; field++)
- {
- if ((len=(ulong) net_field_length(&pos)) == NULL_LENGTH)
- { /* null field */
- row[field] = 0;
- *lengths++=0;
- }
- else
- {
- row[field] = (char*) pos;
- pos+=len;
- *lengths++=len;
- }
- if (prev_pos)
- *prev_pos=0; /* Terminate prev field */
- prev_pos=pos;
- }
- row[field]=(char*) prev_pos+1; /* End of last field */
- *prev_pos=0; /* Terminate last field */
- return 0;
-}
-
-/****************************************************************************
-** Init MySQL structure or allocate one
-****************************************************************************/
-
-MYSQL * STDCALL
-mysql_init(MYSQL *mysql)
-{
- mysql_once_init();
- if (!mysql)
- {
- if (!(mysql=(MYSQL*) my_malloc(sizeof(*mysql),MYF(MY_WME | MY_ZEROFILL))))
- return 0;
- mysql->free_me=1;
- mysql->net.vio = 0;
- }
- else
- bzero((char*) (mysql),sizeof(*(mysql)));
-#ifdef __WIN32__
- mysql->options.connect_timeout=20;
-#endif
- return mysql;
-}
-
-
-static void mysql_once_init()
-{
- if (!mysql_client_init)
- {
- mysql_client_init=1;
- my_init(); /* Will init threads */
- init_client_errs();
- if (!mysql_port)
- {
- mysql_port = MYSQL_PORT;
-#ifndef MSDOS
- {
- struct servent *serv_ptr;
- char *env;
- if ((serv_ptr = getservbyname("mysql", "tcp")))
- mysql_port = (uint) ntohs((ushort) serv_ptr->s_port);
- if ((env = getenv("MYSQL_TCP_PORT")))
- mysql_port =(uint) atoi(env);
- }
-#endif
- }
- if (!mysql_unix_port)
- {
- char *env;
-#ifdef __WIN32__
- mysql_unix_port = (char*) MYSQL_NAMEDPIPE;
-#else
- mysql_unix_port = (char*) MYSQL_UNIX_ADDR;
-#endif
- if ((env = getenv("MYSQL_UNIX_PORT")))
- mysql_unix_port = env;
- }
- mysql_debug(NullS);
-#if defined(SIGPIPE) && !defined(THREAD)
- (void) signal(SIGPIPE,SIG_IGN);
-#endif
- }
-#ifdef THREAD
- else
- my_thread_init(); /* Init if new thread */
-#endif
-}
-
-#ifdef HAVE_OPENSSL
-/**************************************************************************
-** Fill in SSL part of MYSQL structure and set 'use_ssl' flag.
-** NB! Errors are not reported until you do mysql_real_connect.
-**************************************************************************/
-
-int STDCALL
-mysql_ssl_set(MYSQL *mysql, const char *key, const char *cert,
- const char *ca, const char *capath)
-{
- mysql->options.ssl_key = key==0 ? 0 : my_strdup(key,MYF(0));
- mysql->options.ssl_cert = cert==0 ? 0 : my_strdup(cert,MYF(0));
- mysql->options.ssl_ca = ca==0 ? 0 : my_strdup(ca,MYF(0));
- mysql->options.ssl_capath = capath==0 ? 0 : my_strdup(capath,MYF(0));
- mysql->options.use_ssl = true;
- mysql->connector_fd = new_VioSSLConnectorFd(key, cert, ca, capath);
- return 0;
-}
-
-/**************************************************************************
-**************************************************************************/
-
-char * STDCALL
-mysql_ssl_cipher(MYSQL *mysql)
-{
- return (char *)mysql->net.vio->cipher_description();
-}
-
-
-/**************************************************************************
-** Free strings in the SSL structure and clear 'use_ssl' flag.
-** NB! Errors are not reported until you do mysql_real_connect.
-**************************************************************************/
-
-int STDCALL
-mysql_ssl_clear(MYSQL *mysql)
-{
- my_free(mysql->options.ssl_key, MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.ssl_cert, MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.ssl_ca, MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.ssl_capath, MYF(MY_ALLOW_ZERO_PTR));
- mysql->options.ssl_key = 0;
- mysql->options.ssl_cert = 0;
- mysql->options.ssl_ca = 0;
- mysql->options.ssl_capath = 0;
- mysql->options.use_ssl = false;
- delete reinterpret_cast<VioConnectorFd*>(mysql->connector_fd);
- mysql->connector_fd = 0;
- return 0;
-}
-#endif /* HAVE_OPENSSL */
-
-/**************************************************************************
-** Connect to sql server
-** If host == 0 then use localhost
-**************************************************************************/
-
-MYSQL * STDCALL
-mysql_connect(MYSQL *mysql,const char *host,
- const char *user, const char *passwd)
-{
- MYSQL *res;
- mysql=mysql_init(mysql); /* Make it thread safe */
- {
- DBUG_ENTER("mysql_connect");
- if (!(res=mysql_real_connect(mysql,host,user,passwd,NullS,0,NullS,0)))
- {
- if (mysql->free_me)
- my_free((gptr) mysql,MYF(0));
- }
- DBUG_RETURN(res);
- }
-}
-
-
-/*
-** Note that the mysql argument must be initialized with mysql_init()
-** before calling mysql_real_connect !
-*/
-
-MYSQL * STDCALL
-mysql_real_connect(MYSQL *mysql,const char *host, const char *user,
- const char *passwd, const char *db,
- uint port, const char *unix_socket,uint client_flag)
-{
- char buff[100],*end,*host_info;
- int sock;
- ulong ip_addr;
- struct sockaddr_in sock_addr;
- uint pkt_length;
- NET *net;
-#ifdef __WIN32__
- HANDLE hPipe=INVALID_HANDLE_VALUE;
-#endif
-#ifdef HAVE_SYS_UN_H
- struct sockaddr_un UNIXaddr;
-#endif
- init_sigpipe_variables
- DBUG_ENTER("mysql_real_connect");
-
- DBUG_PRINT("enter",("host: %s db: %s user: %s",
- host ? host : "(Null)",
- db ? db : "(Null)",
- user ? user : "(Null)"));
-
- /* Don't give sigpipe errors if the client doesn't want them */
- set_sigpipe(mysql);
- /* use default options */
- if (mysql->options.my_cnf_file || mysql->options.my_cnf_group)
- {
- mysql_read_default_options(&mysql->options,
- (mysql->options.my_cnf_file ?
- mysql->options.my_cnf_file : "my"),
- mysql->options.my_cnf_group);
- my_free(mysql->options.my_cnf_file,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.my_cnf_group,MYF(MY_ALLOW_ZERO_PTR));
- mysql->options.my_cnf_file=mysql->options.my_cnf_group=0;
- }
-
- /* Some empty-string-tests are done because of ODBC */
- if (!host || !host[0])
- host=mysql->options.host;
- if (!user || !user[0])
- user=mysql->options.user;
- if (!passwd)
- {
- passwd=mysql->options.password;
-#ifndef DONT_USE_MYSQL_PWD
- if (!passwd)
- passwd=getenv("MYSQL_PWD"); /* get it from environment (haneke) */
-#endif
- }
- if (!db || !db[0])
- db=mysql->options.db;
- if (!port)
- port=mysql->options.port;
- if (!unix_socket)
- unix_socket=mysql->options.unix_socket;
-
- remember_connection(mysql);
- mysql->reconnect=1; /* Reconnect as default */
- net= &mysql->net;
- net->vio = 0; /* If something goes wrong */
-
- /*
- ** Grab a socket and connect it to the server
- */
-
-#if defined(HAVE_SYS_UN_H)
- if ((!host || !strcmp(host,LOCAL_HOST)) && (unix_socket || mysql_unix_port))
- {
- host=LOCAL_HOST;
- if (!unix_socket)
- unix_socket=mysql_unix_port;
- host_info=(char*) ER(CR_LOCALHOST_CONNECTION);
- DBUG_PRINT("info",("Using UNIX sock '%s'",unix_socket));
- if ((sock = socket(AF_UNIX,SOCK_STREAM,0)) == SOCKET_ERROR)
- {
- net->last_errno=CR_SOCKET_CREATE_ERROR;
- sprintf(net->last_error,ER(net->last_errno),ERRNO);
- goto error;
- }
- net->vio = vio_new(sock, VIO_TYPE_SOCKET, TRUE);
- bzero((char*) &UNIXaddr,sizeof(UNIXaddr));
- UNIXaddr.sun_family = AF_UNIX;
- strmov(UNIXaddr.sun_path, unix_socket);
- if (connect2(sock,(struct sockaddr *) &UNIXaddr, sizeof(UNIXaddr),
- mysql->options.connect_timeout) <0)
- {
- DBUG_PRINT("error",("Got error %d on connect to local server",ERRNO));
- net->last_errno=CR_CONNECTION_ERROR;
- sprintf(net->last_error,ER(net->last_errno),unix_socket,ERRNO);
- goto error;
- }
- }
- else
-#elif defined(__WIN32__)
- {
- if ((unix_socket ||
- !host && is_NT() ||
- host && !strcmp(host,LOCAL_HOST_NAMEDPIPE) ||
- mysql->options.named_pipe || !have_tcpip))
- {
- sock=0;
- if ((hPipe=create_named_pipe(net, mysql->options.connect_timeout,
- (char**) &host, (char**) &unix_socket)) ==
- INVALID_HANDLE_VALUE)
- {
- DBUG_PRINT("error",
- ("host: '%s' socket: '%s' named_pipe: %d have_tcpip: %d",
- host ? host : "<null>",
- unix_socket ? unix_socket : "<null>",
- (int) mysql->options.named_pipe,
- (int) have_tcpip));
- if (mysql->options.named_pipe ||
- (host && !strcmp(host,LOCAL_HOST_NAMEDPIPE)) ||
- (unix_socket && !strcmp(unix_socket,MYSQL_NAMEDPIPE)))
- goto error; /* User only requested named pipes */
- /* Try also with TCP/IP */
- }
- else
- {
- net->vio=vio_new_win32pipe(hPipe);
- sprintf(host_info=buff, ER(CR_NAMEDPIPE_CONNECTION), host,
- unix_socket);
- }
- }
- }
- if (hPipe == INVALID_HANDLE_VALUE)
-#endif
- {
- unix_socket=0; /* This is not used */
- if (!port)
- port=mysql_port;
- if (!host)
- host=LOCAL_HOST;
- sprintf(host_info=buff,ER(CR_TCP_CONNECTION),host);
- DBUG_PRINT("info",("Server name: '%s'. TCP sock: %d", host,port));
- if ((sock = socket(AF_INET,SOCK_STREAM,0)) == SOCKET_ERROR)
- {
- net->last_errno=CR_IPSOCK_ERROR;
- sprintf(net->last_error,ER(net->last_errno),ERRNO);
- goto error;
- }
- net->vio = vio_new(sock,VIO_TYPE_TCPIP,FALSE);
- bzero((char*) &sock_addr,sizeof(sock_addr));
- sock_addr.sin_family = AF_INET;
-
- /*
- ** The server name may be a host name or IP address
- */
-
- if ((int) (ip_addr = inet_addr(host)) != (int) INADDR_NONE)
- {
- memcpy(&sock_addr.sin_addr,&ip_addr,sizeof(ip_addr));
- }
- else
-#if defined(HAVE_GETHOSTBYNAME_R) && defined(_REENTRANT) && defined(THREAD)
- {
- int tmp_errno;
- struct hostent tmp_hostent,*hp;
- char buff2[GETHOSTBYNAME_BUFF_SIZE];
- hp = my_gethostbyname_r(host,&tmp_hostent,buff2,sizeof(buff2),
- &tmp_errno);
- if (!hp)
- {
- net->last_errno=CR_UNKNOWN_HOST;
- sprintf(net->last_error, ER(CR_UNKNOWN_HOST), host, tmp_errno);
- goto error;
- }
- memcpy(&sock_addr.sin_addr,hp->h_addr, (size_t) hp->h_length);
- }
-#else
- {
- struct hostent *hp;
- if (!(hp=gethostbyname(host)))
- {
- net->last_errno=CR_UNKNOWN_HOST;
- sprintf(net->last_error, ER(CR_UNKNOWN_HOST), host, errno);
- goto error;
- }
- memcpy(&sock_addr.sin_addr,hp->h_addr, (size_t) hp->h_length);
- }
-#endif
- sock_addr.sin_port = (ushort) htons((ushort) port);
- if (connect2(sock,(struct sockaddr *) &sock_addr, sizeof(sock_addr),
- mysql->options.connect_timeout) <0)
- {
- DBUG_PRINT("error",("Got error %d on connect to '%s'",ERRNO,host));
- net->last_errno= CR_CONN_HOST_ERROR;
- sprintf(net->last_error ,ER(CR_CONN_HOST_ERROR), host, ERRNO);
- goto error;
- }
- }
-
- if (!net->vio || my_net_init(net, net->vio))
- {
- vio_delete(net->vio);
- net->last_errno=CR_OUT_OF_MEMORY;
- strmov(net->last_error,ER(net->last_errno));
- goto error;
- }
- vio_keepalive(net->vio,TRUE);
-
- /* Get version info */
- mysql->protocol_version= PROTOCOL_VERSION; /* Assume this */
- if ((pkt_length=net_safe_read(mysql)) == packet_error)
- goto error;
-
- /* Check if version of protocoll matches current one */
-
- mysql->protocol_version= net->read_pos[0];
- DBUG_DUMP("packet",(char*) net->read_pos,10);
- DBUG_PRINT("info",("mysql protocol version %d, server=%d",
- PROTOCOL_VERSION, mysql->protocol_version));
- if (mysql->protocol_version != PROTOCOL_VERSION &&
- mysql->protocol_version != PROTOCOL_VERSION-1)
- {
- net->last_errno= CR_VERSION_ERROR;
- sprintf(net->last_error, ER(CR_VERSION_ERROR), mysql->protocol_version,
- PROTOCOL_VERSION);
- goto error;
- }
- end=strend((char*) net->read_pos+1);
- mysql->thread_id=uint4korr(end+1);
- end+=5;
- strmake(mysql->scramble_buff,end,8);
- if (pkt_length > (uint) (end+9 - (char*) net->read_pos))
- mysql->server_capabilities=uint2korr(end+9);
-
- /* Save connection information */
- if (!user) user="";
- if (!passwd) passwd="";
- if (!my_multi_malloc(MYF(0),
- &mysql->host_info,strlen(host_info)+1,
- &mysql->host,strlen(host)+1,
- &mysql->unix_socket,unix_socket ? strlen(unix_socket)+1
- :1,
- &mysql->server_version,
- (uint) (end - (char*) net->read_pos),
- NullS) ||
- !(mysql->user=my_strdup(user,MYF(0))) ||
- !(mysql->passwd=my_strdup(passwd,MYF(0))))
- {
- strmov(net->last_error, ER(net->last_errno=CR_OUT_OF_MEMORY));
- goto error;
- }
- strmov(mysql->host_info,host_info);
- strmov(mysql->host,host);
- if (unix_socket)
- strmov(mysql->unix_socket,unix_socket);
- else
- mysql->unix_socket=0;
- strmov(mysql->server_version,(char*) net->read_pos+1);
- mysql->port=port;
- mysql->client_flag=client_flag | mysql->options.client_flag;
- DBUG_PRINT("info",("Server version = '%s' capabilites: %ld",
- mysql->server_version,mysql->server_capabilities));
-
- /* Send client information for access check */
- client_flag|=CLIENT_CAPABILITIES;
-
-#ifdef HAVE_OPENSSL
- if (mysql->options.use_ssl)
- client_flag|=CLIENT_SSL;
-#endif /* HAVE_OPENSSL */
-
- if (db)
- client_flag|=CLIENT_CONNECT_WITH_DB;
-#ifdef HAVE_COMPRESS
- if (mysql->server_capabilities & CLIENT_COMPRESS &&
- (mysql->options.compress || client_flag & CLIENT_COMPRESS))
- client_flag|=CLIENT_COMPRESS; /* We will use compression */
- else
-#endif
- client_flag&= ~CLIENT_COMPRESS;
-
-#ifdef HAVE_OPENSSL
- if ((mysql->server_capabilities & CLIENT_SSL) &&
- (mysql->options.use_ssl || (client_flag & CLIENT_SSL)))
- {
- DBUG_PRINT("info", ("Changing IO layer to SSL"));
- client_flag |= CLIENT_SSL;
- }
- else
- {
- if (client_flag & CLIENT_SSL)
- {
- DBUG_PRINT("info", ("Leaving IO layer intact because server doesn't support SSL"));
- }
- client_flag &= ~CLIENT_SSL;
- }
-#endif /* HAVE_OPENSSL */
-
- int2store(buff,client_flag);
- mysql->client_flag=client_flag;
-
-#ifdef HAVE_OPENSSL
- /* Oops.. are we careful enough to not send ANY information */
- /* without encryption? */
- if (client_flag & CLIENT_SSL)
- {
- if (my_net_write(net,buff,(uint) (2)) || net_flush(net))
- goto error;
- /* Do the SSL layering. */
- DBUG_PRINT("info", ("IO layer change in progress..."));
- VioSSLConnectorFd* connector_fd = (VioSSLConnectorFd*)
- (mysql->connector_fd);
- VioSocket* vio_socket = (VioSocket*)(mysql->net.vio);
- VioSSL* vio_ssl = connector_fd->connect(vio_socket);
- mysql->net.vio = (NetVio*)(vio_ssl);
- }
-#endif /* HAVE_OPENSSL */
-
- int3store(buff+2,max_allowed_packet);
- if (user && user[0])
- strmake(buff+5,user,32);
- else
- read_user_name((char*) buff+5);
-#ifdef _CUSTOMCONFIG_
-#include "_cust_libmysql.h";
-#endif
- DBUG_PRINT("info",("user: %s",buff+5));
- end=scramble(strend(buff+5)+1, mysql->scramble_buff, passwd,
- (my_bool) (mysql->protocol_version == 9));
- if (db && (mysql->server_capabilities & CLIENT_CONNECT_WITH_DB))
- {
- end=strmov(end+1,db);
- mysql->db=my_strdup(db,MYF(MY_WME));
- db=0;
- }
- if (my_net_write(net,buff,(uint) (end-buff)) || net_flush(net) ||
- net_safe_read(mysql) == packet_error)
- goto error;
- if (client_flag & CLIENT_COMPRESS) /* We will use compression */
- net->compress=1;
- if (db && mysql_select_db(mysql,db))
- goto error;
- if (mysql->options.init_command)
- {
- my_bool reconnect=mysql->reconnect;
- mysql->reconnect=0;
- if (mysql_query(mysql,mysql->options.init_command))
- goto error;
- mysql_free_result(mysql_use_result(mysql));
- mysql->reconnect=reconnect;
- }
-
- DBUG_PRINT("exit",("Mysql handler: %lx",mysql));
- reset_sigpipe(mysql);
- DBUG_RETURN(mysql);
-
-error:
- reset_sigpipe(mysql);
- DBUG_PRINT("error",("message: %u (%s)",net->last_errno,net->last_error));
- {
- /* Free alloced memory */
- my_bool free_me=mysql->free_me;
- end_server(mysql);
- mysql->free_me=0;
- mysql_close(mysql);
- mysql->free_me=free_me;
- }
- DBUG_RETURN(0);
-}
-
-
-static my_bool mysql_reconnect(MYSQL *mysql)
-{
- MYSQL tmp_mysql;
- DBUG_ENTER("mysql_reconnect");
-
- if (!mysql->reconnect || !mysql->host_info)
- DBUG_RETURN(1);
- mysql_init(&tmp_mysql);
- tmp_mysql.options=mysql->options;
- if (!mysql_real_connect(&tmp_mysql,mysql->host,mysql->user,mysql->passwd,
- mysql->db, mysql->port, mysql->unix_socket,
- mysql->client_flag))
- DBUG_RETURN(1);
- tmp_mysql.free_me=mysql->free_me;
- mysql->free_me=0;
- bzero((char*) &mysql->options,sizeof(&mysql->options));
- mysql_close(mysql);
- memcpy(mysql,&tmp_mysql,sizeof(tmp_mysql));
- net_clear(&mysql->net);
- mysql->affected_rows= ~(my_ulonglong) 0;
- DBUG_RETURN(0);
-}
-
-
-/**************************************************************************
-** Change user and database
-**************************************************************************/
-
-my_bool STDCALL mysql_change_user(MYSQL *mysql, const char *user,
- const char *passwd, const char *db)
-{
- char buff[512],*pos=buff;
- DBUG_ENTER("mysql_change_user");
-
- if (!user)
- user="";
- if (!passwd)
- passwd="";
-
- pos=strmov(pos,user)+1;
- pos=scramble(pos, mysql->scramble_buff, passwd,
- (my_bool) (mysql->protocol_version == 9));
- pos=strmov(pos+1,db ? db : "");
- if (simple_command(mysql,COM_CHANGE_USER, buff,(uint) (pos-buff),0))
- DBUG_RETURN(1);
-
- my_free(mysql->user,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->passwd,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->db,MYF(MY_ALLOW_ZERO_PTR));
-
- mysql->user= my_strdup(user,MYF(MY_WME));
- mysql->passwd=my_strdup(passwd,MYF(MY_WME));
- mysql->db= db ? my_strdup(db,MYF(MY_WME)) : 0;
- DBUG_RETURN(0);
-}
-
-
-/**************************************************************************
-** Set current database
-**************************************************************************/
-
-int STDCALL
-mysql_select_db(MYSQL *mysql, const char *db)
-{
- int error;
- DBUG_ENTER("mysql_select_db");
- DBUG_PRINT("enter",("db: '%s'",db));
-
- if ((error=simple_command(mysql,COM_INIT_DB,db,strlen(db),0)))
- DBUG_RETURN(error);
- my_free(mysql->db,MYF(MY_ALLOW_ZERO_PTR));
- mysql->db=my_strdup(db,MYF(MY_WME));
- DBUG_RETURN(0);
-}
-
-
-/*************************************************************************
-** Send a QUIT to the server and close the connection
-** If handle is alloced by mysql connect free it.
-*************************************************************************/
-
-void STDCALL
-mysql_close(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_close");
- if (mysql) /* Some simple safety */
- {
- if (mysql->net.vio != 0)
- {
- free_old_query(mysql);
- mysql->status=MYSQL_STATUS_READY; /* Force command */
- simple_command(mysql,COM_QUIT,NullS,0,1);
- end_server(mysql);
- }
- my_free((gptr) mysql->host_info,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->user,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->passwd,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->db,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.init_command,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.user,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.password,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.unix_socket,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.db,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.my_cnf_file,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->options.my_cnf_group,MYF(MY_ALLOW_ZERO_PTR));
- /* Clear pointers for better safety */
- mysql->host_info=mysql->user=mysql->passwd=mysql->db=0;
- bzero((char*) &mysql->options,sizeof(mysql->options));
- mysql->net.vio = 0;
-#ifdef HAVE_OPENSSL
- ((VioConnectorFd*)(mysql->connector_fd))->delete();
- mysql->connector_fd = 0;
-#endif /* HAVE_OPENSSL */
- if (mysql->free_me)
- my_free((gptr) mysql,MYF(0));
- }
- DBUG_VOID_RETURN;
-}
-
-
-/**************************************************************************
-** Do a query. If query returned rows, free old rows.
-** Read data by mysql_store_result or by repeat call of mysql_fetch_row
-**************************************************************************/
-
-int STDCALL
-mysql_query(MYSQL *mysql, const char *query)
-{
- return mysql_real_query(mysql,query,strlen(query));
-}
-
-
-int STDCALL
-mysql_real_query(MYSQL *mysql, const char *query,uint length)
-{
- uchar *pos;
- ulong field_count;
- MYSQL_DATA *fields;
- DBUG_ENTER("mysql_real_query");
- DBUG_PRINT("enter",("handle: %lx",mysql));
- DBUG_PRINT("query",("Query = \"%s\"",query));
-
- if (simple_command(mysql,COM_QUERY,query,length,1) ||
- (length=net_safe_read(mysql)) == packet_error)
- DBUG_RETURN(-1);
- free_old_query(mysql); /* Free old result */
- get_info:
- pos=(uchar*) mysql->net.read_pos;
- if ((field_count= net_field_length(&pos)) == 0)
- {
- mysql->affected_rows= net_field_length_ll(&pos);
- mysql->insert_id= net_field_length_ll(&pos);
- if (pos < mysql->net.read_pos+length && net_field_length(&pos))
- mysql->info=(char*) pos;
- DBUG_RETURN(0);
- }
- if (field_count == NULL_LENGTH) /* LOAD DATA LOCAL INFILE */
- {
- int error=send_file_to_server(mysql,(char*) pos);
- if ((length=net_safe_read(mysql)) == packet_error || error)
- DBUG_RETURN(-1);
- goto get_info; /* Get info packet */
- }
- mysql->extra_info= net_field_length_ll(&pos); /* Maybe number of rec */
- if (!(fields=read_rows(mysql,(MYSQL_FIELD*) 0,5)))
- DBUG_RETURN(-1);
- if (!(mysql->fields=unpack_fields(fields,&mysql->field_alloc,
- (uint) field_count,0,
- (my_bool) test(mysql->server_capabilities &
- CLIENT_LONG_FLAG))))
- DBUG_RETURN(-1);
- mysql->status=MYSQL_STATUS_GET_RESULT;
- mysql->field_count=field_count;
- DBUG_RETURN(0);
-}
-
-
-static int
-send_file_to_server(MYSQL *mysql, const char *filename)
-{
- int fd, readcount;
- char buf[IO_SIZE*15],*tmp_name;
- DBUG_ENTER("send_file_to_server");
-
- fn_format(buf,filename,"","",4); /* Convert to client format */
- if (!(tmp_name=my_strdup(buf,MYF(0))))
- {
- strmov(mysql->net.last_error, ER(mysql->net.last_errno=CR_OUT_OF_MEMORY));
- DBUG_RETURN(-1);
- }
- if ((fd = my_open(tmp_name,O_RDONLY, MYF(0))) < 0)
- {
- mysql->net.last_errno=EE_FILENOTFOUND;
- sprintf(buf,EE(mysql->net.last_errno),tmp_name,errno);
- strmake(mysql->net.last_error,buf,sizeof(mysql->net.last_error)-1);
- my_net_write(&mysql->net,"",0); net_flush(&mysql->net);
- my_free(tmp_name,MYF(0));
- DBUG_RETURN(-1);
- }
-
- while ((readcount = (int) my_read(fd,buf,sizeof(buf),MYF(0))) > 0)
- {
- if (my_net_write(&mysql->net,buf,readcount))
- {
- mysql->net.last_errno=CR_SERVER_LOST;
- strmov(mysql->net.last_error,ER(mysql->net.last_errno));
- DBUG_PRINT("error",("Lost connection to MySQL server during LOAD DATA of local file"));
- (void) my_close(fd,MYF(0));
- my_free(tmp_name,MYF(0));
- DBUG_RETURN(-1);
- }
- }
- (void) my_close(fd,MYF(0));
- /* Send empty packet to mark end of file */
- if (my_net_write(&mysql->net,"",0) || net_flush(&mysql->net))
- {
- mysql->net.last_errno=CR_SERVER_LOST;
- sprintf(mysql->net.last_error,ER(mysql->net.last_errno),errno);
- my_free(tmp_name,MYF(0));
- DBUG_RETURN(-1);
- }
- if (readcount < 0)
- {
- mysql->net.last_errno=EE_READ; /* the errmsg for not entire file read */
- sprintf(buf,EE(mysql->net.last_errno),tmp_name,errno);
- strmake(mysql->net.last_error,buf,sizeof(mysql->net.last_error)-1);
- my_free(tmp_name,MYF(0));
- DBUG_RETURN(-1);
- }
- DBUG_RETURN(0);
-}
-
-
-/**************************************************************************
-** Alloc result struct for buffered results. All rows are read to buffer.
-** mysql_data_seek may be used.
-**************************************************************************/
-
-MYSQL_RES * STDCALL
-mysql_store_result(MYSQL *mysql)
-{
- MYSQL_RES *result;
- DBUG_ENTER("mysql_store_result");
-
- if (!mysql->fields)
- DBUG_RETURN(0);
- if (mysql->status != MYSQL_STATUS_GET_RESULT)
- {
- strmov(mysql->net.last_error,
- ER(mysql->net.last_errno=CR_COMMANDS_OUT_OF_SYNC));
- DBUG_RETURN(0);
- }
- mysql->status=MYSQL_STATUS_READY; /* server is ready */
- if (!(result=(MYSQL_RES*) my_malloc(sizeof(MYSQL_RES)+
- sizeof(ulong)*mysql->field_count,
- MYF(MY_WME | MY_ZEROFILL))))
- {
- mysql->net.last_errno=CR_OUT_OF_MEMORY;
- strmov(mysql->net.last_error, ER(mysql->net.last_errno));
- DBUG_RETURN(0);
- }
- result->eof=1; /* Marker for buffered */
- result->lengths=(ulong*) (result+1);
- if (!(result->data=read_rows(mysql,mysql->fields,mysql->field_count)))
- {
- my_free((gptr) result,MYF(0));
- DBUG_RETURN(0);
- }
- mysql->affected_rows= result->row_count= result->data->rows;
- result->data_cursor= result->data->data;
- result->fields= mysql->fields;
- result->field_alloc= mysql->field_alloc;
- result->field_count= mysql->field_count;
- result->current_field=0;
- result->current_row=0; /* Must do a fetch first */
- mysql->fields=0; /* fields is now in result */
- DBUG_RETURN(result); /* Data fetched */
-}
-
-
-/**************************************************************************
-** Alloc struct for use with unbuffered reads. Data is fetched by domand
-** when calling to mysql_fetch_row.
-** mysql_data_seek is a noop.
-**
-** No other queries may be specified with the same MYSQL handle.
-** There shouldn't be much processing per row because mysql server shouldn't
-** have to wait for the client (and will not wait more than 30 sec/packet).
-**************************************************************************/
-
-MYSQL_RES * STDCALL
-mysql_use_result(MYSQL *mysql)
-{
- MYSQL_RES *result;
- DBUG_ENTER("mysql_use_result");
-
- if (!mysql->fields)
- DBUG_RETURN(0);
- if (mysql->status != MYSQL_STATUS_GET_RESULT)
- {
- strmov(mysql->net.last_error,
- ER(mysql->net.last_errno=CR_COMMANDS_OUT_OF_SYNC));
- DBUG_RETURN(0);
- }
- if (!(result=(MYSQL_RES*) my_malloc(sizeof(*result)+
- sizeof(ulong)*mysql->field_count,
- MYF(MY_WME | MY_ZEROFILL))))
- DBUG_RETURN(0);
- result->lengths=(ulong*) (result+1);
- if (!(result->row=(MYSQL_ROW)
- my_malloc(sizeof(result->row[0])*(mysql->field_count+1), MYF(MY_WME))))
- { /* Ptrs: to one row */
- my_free((gptr) result,MYF(0));
- DBUG_RETURN(0);
- }
- result->fields= mysql->fields;
- result->field_alloc= mysql->field_alloc;
- result->field_count= mysql->field_count;
- result->current_field=0;
- result->handle= mysql;
- result->current_row= 0;
- mysql->fields=0; /* fields is now in result */
- mysql->status=MYSQL_STATUS_USE_RESULT;
- DBUG_RETURN(result); /* Data is read to be fetched */
-}
-
-
-
-/**************************************************************************
-** Return next field of the query results
-**************************************************************************/
-
-MYSQL_FIELD * STDCALL
-mysql_fetch_field(MYSQL_RES *result)
-{
- if (result->current_field >= result->field_count)
- return(NULL);
- return &result->fields[result->current_field++];
-}
-
-
-/**************************************************************************
-** Return next row of the query results
-**************************************************************************/
-
-MYSQL_ROW STDCALL
-mysql_fetch_row(MYSQL_RES *res)
-{
- DBUG_ENTER("mysql_fetch_row");
- if (!res->data)
- { /* Unbufferred fetch */
- if (!res->eof)
- {
- if (!(read_one_row(res->handle,res->field_count,res->row, res->lengths)))
- {
- res->row_count++;
- DBUG_RETURN(res->current_row=res->row);
- }
- else
- {
- res->eof=1;
- res->handle->status=MYSQL_STATUS_READY;
- }
- }
- DBUG_RETURN((MYSQL_ROW) NULL);
- }
- {
- MYSQL_ROW tmp;
- if (!res->data_cursor)
- DBUG_RETURN(res->current_row=(MYSQL_ROW) NULL);
- tmp = res->data_cursor->data;
- res->data_cursor = res->data_cursor->next;
- DBUG_RETURN(res->current_row=tmp);
- }
-}
-
-/**************************************************************************
-** Get column lengths of the current row
-** If one uses mysql_use_result, res->lengths contains the length information,
-** else the lengths are calculated from the offset between pointers.
-**************************************************************************/
-
-ulong * STDCALL
-mysql_fetch_lengths(MYSQL_RES *res)
-{
- ulong *lengths,*prev_length;
- byte *start;
- MYSQL_ROW column,end;
-
- if (!(column=res->current_row))
- return 0; /* Something is wrong */
- if (res->data)
- {
- start=0;
- prev_length=0; /* Keep gcc happy */
- lengths=res->lengths;
- for (end=column+res->field_count+1 ; column != end ; column++,lengths++)
- {
- if (!*column)
- {
- *lengths=0; /* Null */
- continue;
- }
- if (start) /* Found end of prev string */
- *prev_length= (uint) (*column-start-1);
- start= *column;
- prev_length=lengths;
- }
- }
- return res->lengths;
-}
-
-/**************************************************************************
-** Move to a specific row and column
-**************************************************************************/
-
-void STDCALL
-mysql_data_seek(MYSQL_RES *result, my_ulonglong row)
-{
- MYSQL_ROWS *tmp=0;
- DBUG_PRINT("info",("mysql_data_seek(%d)",row));
- if (result->data)
- for (tmp=result->data->data; row-- && tmp ; tmp = tmp->next) ;
- result->current_row=0;
- result->data_cursor = tmp;
-}
-
-/*************************************************************************
-** put the row or field cursor one a position one got from mysql_row_tell()
-** This dosen't restore any data. The next mysql_fetch_row or
-** mysql_fetch_field will return the next row or field after the last used
-*************************************************************************/
-
-MYSQL_ROW_OFFSET STDCALL
-mysql_row_seek(MYSQL_RES *result, MYSQL_ROW_OFFSET row)
-{
- MYSQL_ROW_OFFSET return_value=result->data_cursor;
- result->current_row= 0;
- result->data_cursor= row;
- return return_value;
-}
-
-
-MYSQL_FIELD_OFFSET STDCALL
-mysql_field_seek(MYSQL_RES *result, MYSQL_FIELD_OFFSET field_offset)
-{
- MYSQL_FIELD_OFFSET return_value=result->current_field;
- result->current_field=field_offset;
- return return_value;
-}
-
-/*****************************************************************************
-** List all databases
-*****************************************************************************/
-
-MYSQL_RES * STDCALL
-mysql_list_dbs(MYSQL *mysql, const char *wild)
-{
- char buff[255];
- DBUG_ENTER("mysql_list_dbs");
-
- append_wild(strmov(buff,"show databases"),buff+sizeof(buff),wild);
- if (mysql_query(mysql,buff))
- DBUG_RETURN(0);
- DBUG_RETURN (mysql_store_result(mysql));
-}
-
-
-/*****************************************************************************
-** List all tables in a database
-** If wild is given then only the tables matching wild is returned
-*****************************************************************************/
-
-MYSQL_RES * STDCALL
-mysql_list_tables(MYSQL *mysql, const char *wild)
-{
- char buff[255];
- DBUG_ENTER("mysql_list_tables");
-
- append_wild(strmov(buff,"show tables"),buff+sizeof(buff),wild);
- if (mysql_query(mysql,buff))
- DBUG_RETURN(0);
- DBUG_RETURN (mysql_store_result(mysql));
-}
-
-
-/**************************************************************************
-** List all fields in a table
-** If wild is given then only the fields matching wild is returned
-** Instead of this use query:
-** show fields in 'table' like "wild"
-**************************************************************************/
-
-MYSQL_RES * STDCALL
-mysql_list_fields(MYSQL *mysql, const char *table, const char *wild)
-{
- MYSQL_RES *result;
- MYSQL_DATA *query;
- char buff[257],*end;
- DBUG_ENTER("mysql_list_fields");
- DBUG_PRINT("enter",("table: '%s' wild: '%s'",table,wild ? wild : ""));
-
- LINT_INIT(query);
-
- end=strmake(strmake(buff, table,128)+1,wild ? wild : "",128);
- if (simple_command(mysql,COM_FIELD_LIST,buff,(uint) (end-buff),1) ||
- !(query = read_rows(mysql,(MYSQL_FIELD*) 0,6)))
- DBUG_RETURN(NULL);
-
- free_old_query(mysql);
- if (!(result = (MYSQL_RES *) my_malloc(sizeof(MYSQL_RES),
- MYF(MY_WME | MY_ZEROFILL))))
- {
- free_rows(query);
- DBUG_RETURN(NULL);
- }
- result->field_alloc=mysql->field_alloc;
- mysql->fields=0;
- result->field_count = (uint) query->rows;
- result->fields= unpack_fields(query,&result->field_alloc,
- result->field_count,1,
- (my_bool) test(mysql->server_capabilities &
- CLIENT_LONG_FLAG));
- result->eof=1;
- DBUG_RETURN(result);
-}
-
-/* List all running processes (threads) in server */
-
-MYSQL_RES * STDCALL
-mysql_list_processes(MYSQL *mysql)
-{
- MYSQL_DATA *fields;
- uint field_count;
- uchar *pos;
- DBUG_ENTER("mysql_list_processes");
-
- LINT_INIT(fields);
- if (simple_command(mysql,COM_PROCESS_INFO,0,0,0))
- DBUG_RETURN(0);
- free_old_query(mysql);
- pos=(uchar*) mysql->net.read_pos;
- field_count=(uint) net_field_length(&pos);
- if (!(fields = read_rows(mysql,(MYSQL_FIELD*) 0,5)))
- DBUG_RETURN(NULL);
- if (!(mysql->fields=unpack_fields(fields,&mysql->field_alloc,field_count,0,
- (my_bool) test(mysql->server_capabilities &
- CLIENT_LONG_FLAG))))
- DBUG_RETURN(0);
- mysql->status=MYSQL_STATUS_GET_RESULT;
- mysql->field_count=field_count;
- DBUG_RETURN(mysql_store_result(mysql));
-}
-
-
-int STDCALL
-mysql_create_db(MYSQL *mysql, const char *db)
-{
- DBUG_ENTER("mysql_createdb");
- DBUG_PRINT("enter",("db: %s",db));
- DBUG_RETURN(simple_command(mysql,COM_CREATE_DB,db, (uint) strlen(db),0));
-}
-
-
-int STDCALL
-mysql_drop_db(MYSQL *mysql, const char *db)
-{
- DBUG_ENTER("mysql_drop_db");
- DBUG_PRINT("enter",("db: %s",db));
- DBUG_RETURN(simple_command(mysql,COM_DROP_DB,db,(uint) strlen(db),0));
-}
-
-
-int STDCALL
-mysql_shutdown(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_shutdown");
- DBUG_RETURN(simple_command(mysql,COM_SHUTDOWN,0,0,0));
-}
-
-
-int STDCALL
-mysql_refresh(MYSQL *mysql,uint options)
-{
- uchar bits[1];
- DBUG_ENTER("mysql_refresh");
- bits[0]= (uchar) options;
- DBUG_RETURN(simple_command(mysql,COM_REFRESH,(char*) bits,1,0));
-}
-
-int STDCALL
-mysql_kill(MYSQL *mysql,ulong pid)
-{
- char buff[12];
- DBUG_ENTER("mysql_kill");
- int4store(buff,pid);
- DBUG_RETURN(simple_command(mysql,COM_PROCESS_KILL,buff,4,0));
-}
-
-
-int STDCALL
-mysql_dump_debug_info(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_dump_debug_info");
- DBUG_RETURN(simple_command(mysql,COM_DEBUG,0,0,0));
-}
-
-char * STDCALL
-mysql_stat(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_stat");
- if (simple_command(mysql,COM_STATISTICS,0,0,0))
- return mysql->net.last_error;
- mysql->net.read_pos[mysql->packet_length]=0; /* End of stat string */
- if (!mysql->net.read_pos[0])
- {
- mysql->net.last_errno=CR_WRONG_HOST_INFO;
- strmov(mysql->net.last_error, ER(mysql->net.last_errno));
- return mysql->net.last_error;
- }
- DBUG_RETURN((char*) mysql->net.read_pos);
-}
-
-
-int STDCALL
-mysql_ping(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_ping");
- DBUG_RETURN(simple_command(mysql,COM_PING,0,0,0));
-}
-
-
-char * STDCALL
-mysql_get_server_info(MYSQL *mysql)
-{
- return((char*) mysql->server_version);
-}
-
-
-char * STDCALL
-mysql_get_host_info(MYSQL *mysql)
-{
- return(mysql->host_info);
-}
-
-
-uint STDCALL
-mysql_get_proto_info(MYSQL *mysql)
-{
- return (mysql->protocol_version);
-}
-
-char * STDCALL
-mysql_get_client_info(void)
-{
- return (char*) MYSQL_SERVER_VERSION;
-}
-
-
-int STDCALL
-mysql_options(MYSQL *mysql,enum mysql_option option, const char *arg)
-{
- DBUG_ENTER("mysql_option");
- DBUG_PRINT("enter",("option: %d",(int) option));
- switch (option) {
- case MYSQL_OPT_CONNECT_TIMEOUT:
- mysql->options.connect_timeout= *(uint*) arg;
- break;
- case MYSQL_OPT_COMPRESS:
- mysql->options.compress=1; /* Remember for connect */
- break;
- case MYSQL_OPT_NAMED_PIPE:
- mysql->options.named_pipe=1; /* Force named pipe */
- break;
- case MYSQL_INIT_COMMAND:
- my_free(mysql->options.init_command,MYF(MY_ALLOW_ZERO_PTR));
- mysql->options.init_command=my_strdup(arg,MYF(MY_WME));
- break;
- case MYSQL_READ_DEFAULT_FILE:
- my_free(mysql->options.my_cnf_file,MYF(MY_ALLOW_ZERO_PTR));
- mysql->options.my_cnf_file=my_strdup(arg,MYF(MY_WME));
- break;
- case MYSQL_READ_DEFAULT_GROUP:
- my_free(mysql->options.my_cnf_group,MYF(MY_ALLOW_ZERO_PTR));
- mysql->options.my_cnf_group=my_strdup(arg,MYF(MY_WME));
- break;
- default:
- DBUG_RETURN(-1);
- }
- DBUG_RETURN(0);
-}
-
-/****************************************************************************
-** Functions to get information from the MySQL structure
-** These are functions to make shared libraries more usable.
-****************************************************************************/
-
-/* MYSQL_RES */
-my_ulonglong mysql_num_rows(MYSQL_RES *res)
-{
- return res->row_count;
-}
-
-unsigned int mysql_num_fields(MYSQL_RES *res)
-{
- return res->field_count;
-}
-
-my_bool mysql_eof(MYSQL_RES *res)
-{
- return res->eof;
-}
-
-MYSQL_FIELD *mysql_fetch_field_direct(MYSQL_RES *res,uint fieldnr)
-{
- return &(res)->fields[fieldnr];
-}
-
-MYSQL_FIELD *mysql_fetch_fields(MYSQL_RES *res)
-{
- return (res)->fields;
-}
-
-MYSQL_ROWS *mysql_row_tell(MYSQL_RES *res)
-{
- return res->data_cursor;
-}
-
-uint mysql_field_tell(MYSQL_RES *res)
-{
- return (res)->current_field;
-}
-
-/* MYSQL */
-
-unsigned int mysql_field_count(MYSQL *mysql)
-{
- return mysql->field_count;
-}
-
-my_ulonglong mysql_affected_rows(MYSQL *mysql)
-{
- return (mysql)->affected_rows;
-}
-
-my_ulonglong mysql_insert_id(MYSQL *mysql)
-{
- return (mysql)->insert_id;
-}
-
-uint mysql_errno(MYSQL *mysql)
-{
- return (mysql)->net.last_errno;
-}
-
-char *mysql_error(MYSQL *mysql)
-{
- return (mysql)->net.last_error;
-}
-
-char *mysql_info(MYSQL *mysql)
-{
- return (mysql)->info;
-}
-
-ulong mysql_thread_id(MYSQL *mysql)
-{
- return (mysql)->thread_id;
-}
-
-/****************************************************************************
-** Some support functions
-****************************************************************************/
-
-/*
-** Add escape characters to a string (blob?) to make it suitable for a insert
-** to should at least have place for length*2+1 chars
-** Returns the length of the to string
-*/
-
-ulong STDCALL
-mysql_escape_string(char *to,const char *from,ulong length)
-{
- const char *to_start=to;
- const char *end;
- for (end=from+length; from != end ; from++)
- {
-#ifdef USE_MB
- int l;
- if ((l = ismbchar(from, end)))
- {
- while (l--)
- *to++ = *from++;
- from--;
- continue;
- }
-#endif
- switch (*from) {
- case 0: /* Must be escaped for 'mysql' */
- *to++= '\\';
- *to++= '0';
- break;
- case '\n': /* Must be escaped for logs */
- *to++= '\\';
- *to++= 'n';
- break;
- case '\r':
- *to++= '\\';
- *to++= 'r';
- break;
- case '\\':
- *to++= '\\';
- *to++= '\\';
- break;
- case '\'':
- *to++= '\\';
- *to++= '\'';
- break;
- case '"': /* Better safe than sorry */
- *to++= '\\';
- *to++= '"';
- break;
- case '\032': /* This gives problems on Win32 */
- *to++= '\\';
- *to++= 'Z';
- break;
- default:
- *to++= *from;
- }
- }
- *to=0;
- return (ulong) (to-to_start);
-}
-
-
-char * STDCALL
-mysql_odbc_escape_string(char *to, ulong to_length,
- const char *from, ulong from_length,
- void *param,
- char * (*extend_buffer)
- (void *, char *, ulong *))
-{
- char *to_end=to+to_length-5;
- const char *end;
-
- for (end=from+from_length; from != end ; from++)
- {
- if (to >= to_end)
- {
- to_length = (ulong) (end-from)+512; /* We want this much more */
- if (!(to=(*extend_buffer)(param, to, &to_length)))
- return to;
- to_end=to+to_length-5;
- }
-#ifdef USE_MB
- {
- int l;
- if ((l = ismbchar(from, end)))
- {
- while (l--)
- *to++ = *from++;
- from--;
- continue;
- }
- }
-#endif
- switch (*from) {
- case 0: /* Must be escaped for 'mysql' */
- *to++= '\\';
- *to++= '0';
- break;
- case '\n': /* Must be escaped for logs */
- *to++= '\\';
- *to++= 'n';
- break;
- case '\r':
- *to++= '\\';
- *to++= 'r';
- break;
- case '\\':
- *to++= '\\';
- *to++= '\\';
- break;
- case '\'':
- *to++= '\\';
- *to++= '\'';
- break;
- case '"': /* Better safe than sorry */
- *to++= '\\';
- *to++= '"';
- break;
- case '\032': /* This gives problems on Win32 */
- *to++= '\\';
- *to++= 'Z';
- break;
- default:
- *to++= *from;
- }
- }
- return to;
-}
-
-
-void STDCALL
-myodbc_remove_escape(char *name)
-{
- char *to;
-#ifdef USE_MB
- char *end;
- for (end=name; *end ; end++) ;
-#endif
-
- for (to=name ; *name ; name++)
- {
-#ifdef USE_MB
- int l;
- if( (l = ismbchar( name , end ) ) ) {
- while (l--)
- *to++ = *name++;
- name--;
- continue;
- }
-#endif
- if (*name == '\\' && name[1])
- name++;
- *to++= *name;
- }
- *to=0;
-}
diff --git a/client/Attic/net.c b/client/Attic/net.c
deleted file mode 100644
index 4ea3f002bbc..00000000000
--- a/client/Attic/net.c
+++ /dev/null
@@ -1,628 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* Write and read of logical packets to/from socket
-** Writes are cached into net_buffer_length big packets.
-** Read packets are reallocated dynamicly when reading big packets.
-** Each logical packet has the following pre-info:
-** 3 byte length & 1 byte package-number.
-*/
-
-#ifdef _WIN32
-#include <winsock.h>
-#endif
-#include <global.h>
-#include <violite.h>
-#include <my_sys.h>
-#include <m_string.h>
-#include "mysql.h"
-#include <signal.h>
-#include <errno.h>
-#include <sys/types.h>
-#include <violite.h>
-
-#if !defined(__WIN__) && !defined(MSDOS)
-#include <sys/socket.h>
-#else
-#undef MYSQL_SERVER // Win32 can't handle interrupts
-#endif
-#if !defined(MSDOS) && !defined(__WIN__) && !defined(HAVE_BROKEN_NETINET_INCLUDES) && !defined(__BEOS__)
-#include <netinet/in_systm.h>
-#include <netinet/in.h>
-#include <netinet/ip.h>
-#if !defined(alpha_linux_port)
-#include <netinet/tcp.h>
-#endif
-#endif
-#include "mysqld_error.h"
-#ifdef MYSQL_SERVER
-#include "my_pthread.h"
-#include "thr_alarm.h"
-void sql_print_error(const char *format,...);
-#define RETRY_COUNT mysqld_net_retry_count
-extern ulong mysqld_net_retry_count;
-#else
-typedef my_bool thr_alarm_t;
-typedef my_bool ALARM;
-#define thr_alarm_init(A) (*A)=0
-#define thr_alarm_in_use(A) (A)
-#define thr_end_alarm(A)
-#define thr_alarm(A,B,C) local_thr_alarm((A),(B),(C))
-static inline int local_thr_alarm(my_bool *A,int B __attribute__((unused)),ALARM *C __attribute__((unused)))
-{
- *A=1;
- return 0;
-}
-#define thr_got_alarm(A) 0
-#define RETRY_COUNT 1
-#endif
-
-#ifdef MYSQL_SERVER
-extern ulong bytes_sent, bytes_received;
-extern pthread_mutex_t LOCK_bytes_sent , LOCK_bytes_received;
-#else
-#undef thread_safe_add
-#define thread_safe_add(A,B,C)
-#endif
-
-/*
-** Give error if a too big packet is found
-** The server can change this with the -O switch, but because the client
-** can't normally do this the client should have a bigger max-buffer.
-*/
-
-#ifdef MYSQL_SERVER
-ulong max_allowed_packet=65536;
-extern uint test_flags;
-#else
-ulong max_allowed_packet=16*1024*1024L;
-#endif
-ulong net_buffer_length=8192; /* Default length. Enlarged if necessary */
-
-#define TEST_BLOCKING 8
-static int net_write_buff(NET *net,const char *packet,uint len);
-
-
- /* Init with packet info */
-
-int my_net_init(NET *net, Vio* vio)
-{
- if (!(net->buff=(uchar*) my_malloc(net_buffer_length,MYF(MY_WME))))
- return 1;
- if (net_buffer_length > max_allowed_packet)
- max_allowed_packet=net_buffer_length;
- net->buff_end=net->buff+(net->max_packet=net_buffer_length);
- net->vio = vio;
- net->error=0; net->return_errno=0; net->return_status=0;
- net->timeout=NET_READ_TIMEOUT; /* Timeout for read */
- net->pkt_nr=0;
- net->write_pos=net->read_pos = net->buff;
- net->last_error[0]=0;
- net->compress=0; net->reading_or_writing=0;
- net->where_b = net->remain_in_buf=0;
- net->last_errno=0;
-
- if (vio != 0) /* If real connection */
- {
- net->fd = vio_fd(vio); /* For perl DBI/DBD */
-#if defined(MYSQL_SERVER) && !defined(___WIN__) && !defined(__EMX__)
- if (!(test_flags & TEST_BLOCKING))
- vio_blocking(vio, FALSE);
-#endif
- vio_fastsend(vio,TRUE);
- }
- return 0;
-}
-
-void net_end(NET *net)
-{
- my_free((gptr) net->buff,MYF(MY_ALLOW_ZERO_PTR));
- net->buff=0;
-}
-
-/* Realloc the packet buffer */
-
-static my_bool net_realloc(NET *net, ulong length)
-{
- uchar *buff;
- ulong pkt_length;
- if (length >= max_allowed_packet)
- {
- DBUG_PRINT("error",("Packet too large (%ld)", length));
-#ifdef MYSQL_SERVER
- sql_print_error("Packet too large (%ld)\n", length);
-#else
- fprintf(stderr,"Packet too large (%ld)\n", length);
-#endif
- net->error=1;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_PACKET_TOO_LARGE;
-#endif
- return 1;
- }
- pkt_length = (length+IO_SIZE-1) & ~(IO_SIZE-1);
- if (!(buff=(uchar*) my_realloc((char*) net->buff, pkt_length, MYF(MY_WME))))
- {
- net->error=1;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_OUT_OF_RESOURCES;
-#endif
- return 1;
- }
- net->buff=net->write_pos=buff;
- net->buff_end=buff+(net->max_packet=pkt_length);
- return 0;
-}
-
- /* Remove unwanted characters from connection */
-
-void net_clear(NET *net)
-{
-#ifndef EXTRA_DEBUG
- int count;
- bool is_blocking=vio_is_blocking(net->vio);
- if (is_blocking)
- vio_blocking(net->vio, FALSE);
- if (!vio_is_blocking(net->vio)) /* Safety if SSL */
- {
- while ( (count = vio_read(net->vio, (char*) (net->buff),
- net->max_packet)) > 0)
- DBUG_PRINT("info",("skipped %d bytes from file: %s",
- count,vio_description(net->vio)));
- if (is_blocking)
- vio_blocking(net->vio, TRUE);
- }
-#endif /* EXTRA_DEBUG */
- net->pkt_nr=0; /* Ready for new command */
- net->write_pos=net->buff;
-}
-
- /* Flush write_buffer if not empty. */
-
-int net_flush(NET *net)
-{
- int error=0;
- DBUG_ENTER("net_flush");
- if (net->buff != net->write_pos)
- {
- error=net_real_write(net,(char*) net->buff,
- (uint) (net->write_pos - net->buff));
- net->write_pos=net->buff;
- }
- DBUG_RETURN(error);
-}
-
-
-/*****************************************************************************
-** Write something to server/client buffer
-*****************************************************************************/
-
-
-/*
-** Write a logical packet with packet header
-** Format: Packet length (3 bytes), packet number(1 byte)
-** When compression is used a 3 byte compression length is added
-** NOTE: If compression is used the original package is destroyed!
-*/
-
-int
-my_net_write(NET *net,const char *packet,ulong len)
-{
- uchar buff[NET_HEADER_SIZE];
- int3store(buff,len);
- buff[3]= (net->compress) ? 0 : (uchar) (net->pkt_nr++);
- if (net_write_buff(net,(char*) buff,NET_HEADER_SIZE))
- return 1;
- return net_write_buff(net,packet,len);
-}
-
-int
-net_write_command(NET *net,uchar command,const char *packet,ulong len)
-{
- uchar buff[NET_HEADER_SIZE+1];
- uint length=len+1; /* 1 extra byte for command */
-
- int3store(buff,length);
- buff[3]= (net->compress) ? 0 : (uchar) (net->pkt_nr++);
- buff[4]=command;
- if (net_write_buff(net,(char*) buff,5))
- return 1;
- return test(net_write_buff(net,packet,len) || net_flush(net));
-}
-
-
-static int
-net_write_buff(NET *net,const char *packet,uint len)
-{
- uint left_length=(uint) (net->buff_end - net->write_pos);
-
- while (len > left_length)
- {
- memcpy((char*) net->write_pos,packet,left_length);
- if (net_real_write(net,(char*) net->buff,net->max_packet))
- return 1;
- net->write_pos=net->buff;
- packet+=left_length;
- len-=left_length;
- left_length=net->max_packet;
- }
- memcpy((char*) net->write_pos,packet,len);
- net->write_pos+=len;
- return 0;
-}
-
-/* Read and write using timeouts */
-
-int
-net_real_write(NET *net,const char *packet,ulong len)
-{
- int length;
- char *pos,*end;
- thr_alarm_t alarmed;
-#if (!defined(__WIN__) && !defined(__EMX__))
- ALARM alarm_buff;
-#endif
- uint retry_count=0;
- my_bool net_blocking = vio_is_blocking(net->vio);
- DBUG_ENTER("net_real_write");
-
- if (net->error == 2)
- DBUG_RETURN(-1); /* socket can't be used */
-
- net->reading_or_writing=2;
-#ifdef HAVE_COMPRESS
- if (net->compress)
- {
- ulong complen;
- uchar *b;
- uint header_length=NET_HEADER_SIZE+COMP_HEADER_SIZE;
- if (!(b=(uchar*) my_malloc(len + NET_HEADER_SIZE + COMP_HEADER_SIZE,
- MYF(MY_WME))))
- {
-#ifdef MYSQL_SERVER
- net->last_errno=ER_OUT_OF_RESOURCES;
- net->error=2;
-#endif
- net->reading_or_writing=0;
- DBUG_RETURN(1);
- }
- memcpy(b+header_length,packet,len);
-
- if (my_compress((byte*) b+header_length,&len,&complen))
- {
- DBUG_PRINT("warning",
- ("Compression error; Continuing without compression"));
- complen=0;
- }
- int3store(&b[NET_HEADER_SIZE],complen);
- int3store(b,len);
- b[3]=(uchar) (net->pkt_nr++);
- len+= header_length;
- packet= (char*) b;
- }
-#endif /* HAVE_COMPRESS */
-
- /* DBUG_DUMP("net",packet,len); */
-#ifdef MYSQL_SERVER
- thr_alarm_init(&alarmed);
- if (net_blocking)
- thr_alarm(&alarmed,NET_WRITE_TIMEOUT,&alarm_buff);
-#else
- alarmed=0;
-#endif /* MYSQL_SERVER */
-
- pos=(char*) packet; end=pos+len;
- while (pos != end)
- {
- if ((int) (length=vio_write(net->vio,pos,(size_t) (end-pos))) <= 0)
- {
- my_bool interrupted = vio_should_retry(net->vio);
-#if (!defined(__WIN__) && !defined(__EMX__))
- if ((interrupted || length==0) && !thr_alarm_in_use(alarmed))
- {
- if (!thr_alarm(&alarmed,NET_WRITE_TIMEOUT,&alarm_buff))
- { /* Always true for client */
- if (!vio_is_blocking(net->vio))
- {
- while (vio_blocking(net->vio, TRUE) < 0)
- {
- if (vio_should_retry(net->vio) && retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr,
- "%s: my_net_write: fcntl returned error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- net->error=2; /* Close socket */
- goto end;
- }
- }
- retry_count=0;
- continue;
- }
- }
- else
-#endif /* (!defined(__WIN__) && !defined(__EMX__)) */
- if (thr_alarm_in_use(alarmed) && !thr_got_alarm(alarmed) &&
- interrupted)
- {
- if (retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr, "%s: write looped, aborting thread\n",
- my_progname);
-#endif /* EXTRA_DEBUG */
- }
-#if defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER)
- if (vio_errno(net->vio) == EINTR)
- {
- DBUG_PRINT("warning",("Interrupted write. Retrying..."));
- continue;
- }
-#endif /* defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER) */
- net->error=2; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno= (interrupted ? ER_NET_WRITE_INTERRUPTED :
- ER_NET_ERROR_ON_WRITE);
-#endif /* MYSQL_SERVER */
- break;
- }
- pos+=length;
- thread_safe_add(bytes_sent,length,&LOCK_bytes_sent);
- }
-#ifndef __WIN__
- end:
-#endif
-#ifdef HAVE_COMPRESS
- if (net->compress)
- my_free((char*) packet,MYF(0));
-#endif
- if (thr_alarm_in_use(alarmed))
- {
- thr_end_alarm(&alarmed);
- vio_blocking(net->vio, net_blocking);
- }
- net->reading_or_writing=0;
- DBUG_RETURN(((int) (pos != end)));
-}
-
-
-/*****************************************************************************
-** Read something from server/clinet
-*****************************************************************************/
-
-
-static uint
-my_real_read(NET *net, ulong *complen)
-{
- uchar *pos;
- long length;
- uint i,retry_count=0;
- ulong len=packet_error;
- thr_alarm_t alarmed;
-#if (!defined(__WIN__) && !defined(__EMX__)) || defined(MYSQL_SERVER)
- ALARM alarm_buff;
-#endif
- my_bool net_blocking=vio_is_blocking(net->vio);
- ulong remain= (net->compress ? NET_HEADER_SIZE+COMP_HEADER_SIZE :
- NET_HEADER_SIZE);
- *complen = 0;
-
- net->reading_or_writing=1;
- thr_alarm_init(&alarmed);
-#ifdef MYSQL_SERVER
- if (net_blocking)
- thr_alarm(&alarmed,net->timeout,&alarm_buff);
-#endif /* MYSQL_SERVER */
-
- pos = net->buff + net->where_b; /* net->packet -4 */
- for (i=0 ; i < 2 ; i++)
- {
- while (remain > 0)
- {
- /* First read is done with non blocking mode */
- if ((int) (length=vio_read(net->vio,(char*) pos,remain)) <= 0L)
- {
- my_bool interrupted = vio_should_retry(net->vio);
-
- DBUG_PRINT("info",("vio_read returned %d, errno: %d",
- length, vio_errno(net->vio)));
-#if (!defined(__WIN__) && !defined(__EMX__)) || defined(MYSQL_SERVER)
- /*
- We got an error that there was no data on the socket. We now set up
- an alarm to not 'read forever', change the socket to non blocking
- mode and try again
- */
- if ((interrupted || length == 0) && !thr_alarm_in_use(alarmed))
- {
- if (!thr_alarm(&alarmed,net->timeout,&alarm_buff)) /* Don't wait too long */
- {
- if (!vio_is_blocking(net->vio))
- {
- while (vio_blocking(net->vio,TRUE) < 0)
- {
- if (vio_should_retry(net->vio) &&
- retry_count++ < RETRY_COUNT)
- continue;
- DBUG_PRINT("error",
- ("fcntl returned error %d, aborting thread",
- vio_errno(net->vio)));
-#ifdef EXTRA_DEBUG
- fprintf(stderr,
- "%s: read: fcntl returned error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- len= packet_error;
- net->error=2; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_FCNTL_ERROR;
-#endif
- goto end;
- }
- }
- retry_count=0;
- continue;
- }
- }
-#endif /* (!defined(__WIN__) && !defined(__EMX__)) || defined(MYSQL_SERVER) */
- if (thr_alarm_in_use(alarmed) && !thr_got_alarm(alarmed) &&
- interrupted)
- { /* Probably in MIT threads */
- if (retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr, "%s: read looped with error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- }
-#if defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER)
- if (vio_should_retry(net->vio))
- {
- DBUG_PRINT("warning",("Interrupted read. Retrying..."));
- continue;
- }
-#endif
- DBUG_PRINT("error",("Couldn't read packet: remain: %d errno: %d length: %d alarmed: %d", remain,vio_errno(net->vio),length,alarmed));
- len= packet_error;
- net->error=2; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno= (interrupted ? ER_NET_READ_INTERRUPTED :
- ER_NET_READ_ERROR);
-#endif
- goto end;
- }
- remain -= (ulong) length;
- pos+= (ulong) length;
- thread_safe_add(bytes_received,(ulong) length,&LOCK_bytes_received);
- }
- if (i == 0)
- { /* First parts is packet length */
- ulong helping;
- if (net->buff[net->where_b + 3] != (uchar) net->pkt_nr)
- {
- if (net->buff[net->where_b] != (uchar) 255)
- {
- DBUG_PRINT("error",
- ("Packets out of order (Found: %d, expected %d)",
- (int) net->buff[net->where_b + 3],
- (uint) (uchar) net->pkt_nr));
-#ifdef EXTRA_DEBUG
- fprintf(stderr,"Packets out of order (Found: %d, expected %d)\n",
- (int) net->buff[net->where_b + 3],
- (uint) (uchar) net->pkt_nr);
-#endif
- }
- len= packet_error;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_PACKETS_OUT_OF_ORDER;
-#endif
- goto end;
- }
- net->pkt_nr++;
-#ifdef HAVE_COMPRESS
- if (net->compress)
- {
- /* complen is > 0 if package is really compressed */
- *complen=uint3korr(&(net->buff[net->where_b + NET_HEADER_SIZE]));
- }
-#endif
-
- len=uint3korr(net->buff+net->where_b);
- helping = max(len,*complen) + net->where_b;
- /* The necessary size of net->buff */
- if (helping >= net->max_packet)
- {
- /* We must allocate one extra byte for the end null */
- if (net_realloc(net,helping+1))
- {
- len= packet_error; /* Return error */
- goto end;
- }
- }
- pos=net->buff + net->where_b;
- remain = len;
- }
- }
-
-end:
- if (thr_alarm_in_use(alarmed))
- {
- thr_end_alarm(&alarmed);
- vio_blocking(net->vio, net_blocking);
- }
- net->reading_or_writing=0;
- return(len);
-}
-
-
-uint
-my_net_read(NET *net)
-{
- ulong len,complen;
-
-#ifdef HAVE_COMPRESS
- if (!net->compress)
- {
-#endif
- len = my_real_read (net,&complen);
- net->read_pos = net->buff + net->where_b;
- if (len != packet_error)
- net->read_pos[len]=0; /* Safeguard for mysql_use_result */
- return len;
-#ifdef HAVE_COMPRESS
- }
- if (net->remain_in_buf)
- net->buff[net->buf_length - net->remain_in_buf]=net->save_char;
- for (;;)
- {
- if (net->remain_in_buf)
- {
- uchar *pos = net->buff + net->buf_length - net->remain_in_buf;
- if (net->remain_in_buf >= 4)
- {
- net->length = uint3korr(pos);
- if (net->length <= net->remain_in_buf - 4)
- {
- /* We have a full packet */
- len=net->length;
- net->remain_in_buf -= net->length + 4;
- net->read_pos=pos + 4;
- break; /* We have a full packet */
- }
- }
- /* Move data down to read next data packet after current one */
- if (net->buf_length != net->remain_in_buf)
- {
- memmove(net->buff,pos,net->remain_in_buf);
- net->buf_length=net->remain_in_buf;
- }
- net->where_b=net->buf_length;
- }
- else
- {
- net->where_b=0;
- net->buf_length=0;
- }
-
- if ((len = my_real_read(net,&complen)) == packet_error)
- break;
- if (my_uncompress((byte*) net->buff + net->where_b, &len, &complen))
- {
- len= packet_error;
- net->error=2; /* caller will close socket */
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_UNCOMPRESS_ERROR;
-#endif
- break;
- }
- net->buf_length+=len;
- net->remain_in_buf+=len;
- }
- if (len != packet_error)
- {
- net->save_char= net->read_pos[len]; /* Must be saved */
- net->read_pos[len]=0; /* Safeguard for mysql_use_result */
- }
- return len;
-#endif
-}
diff --git a/extra/Attic/print_defaults.c b/extra/Attic/print_defaults.c
deleted file mode 100644
index a6e67e4949e..00000000000
--- a/extra/Attic/print_defaults.c
+++ /dev/null
@@ -1,125 +0,0 @@
-/* Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public
- License along with this library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
- MA 02111-1307, USA */
-
-/*
-** print_default.c:
-** Print all parameters in a default file that will be given to some program.
-**
-** Written by Monty
-*/
-
-#include <global.h>
-#include <my_sys.h>
-#include <getopt.h>
-
-const char *config_file="my"; /* Default config file */
-
-static struct option long_options[] =
-{
- {"config-file", required_argument, 0, 'c'},
- {"defaults-file", required_argument, 0, 'c'},
- {"no-defaults", no_argument, 0, 'd'},
- {"help", no_argument, 0, '?'},
- {"version", no_argument, 0, 'V'},
- {0, 0, 0, 0}
-};
-
-static void usage(my_bool version)
-{
- printf("%s Ver 1.1 for %s at %s\n",my_progname,SYSTEM_TYPE,
- MACHINE_TYPE);
- if (version)
- return;
- puts("This software comes with ABSOLUTELY NO WARRANTY. This is free software,\nand you are welcome to modify and redistribute it under the GPL license\n");
- puts("Prints all arguments that is give to some program using the default files");
- printf("Usage: %s [OPTIONS] groups\n",my_progname);
- printf("\n\
- -c, --config-file=# --defaults-file=#\n\
- The config file to use (default '%s')\n\
- --no-defaults Return an empty string (useful for scripts)\n\
- -?, --help Display this help message and exit.\n\
- -V, --version Output version information and exit.\n",
- config_file);
- printf("\nExample usage: %s --config-file=my client mysql\n",my_progname);
-}
-
-static int get_options(int *argc,char ***argv)
-{
- int c,option_index;
-
- while ((c=getopt_long(*argc,*argv,"c:V?I",
- long_options, &option_index)) != EOF)
- {
- switch (c) {
- case 'c':
- config_file=optarg;
- break;
- case 'n':
- exit(0);
- case 'I':
- case '?':
- usage(0);
- exit(0);
- case 'V':
- usage(1);
- exit(0);
- }
- }
- (*argc)-=optind;
- (*argv)+=optind;
- if (*argc < 1)
- {
- usage(0);
- return 1;
- }
- return 0;
-}
-
-int main(int argc, char **argv)
-{
- int count;
- char **load_default_groups, *tmp_arguments[2],
- **argument, **arguments;
- MY_INIT(argv[0]);
-
- /*
- ** Check out the args
- */
- if (get_options(&argc,&argv))
- exit(1);
- if (!(load_default_groups=(char**) my_malloc((argc+2)*sizeof(char*),
- MYF(MY_WME))))
- exit(1);
-
- for (count=0; *argv ; argv++,count++)
- load_default_groups[count]= *argv;
- load_default_groups[count]=0;
-
- count=1;
- arguments=tmp_arguments;
- arguments[0]=my_progname;
- arguments[1]=0;
- load_defaults(config_file, (const char **) load_default_groups,
- &count, &arguments);
-
- for (argument= arguments+1 ; *argument ; argument++)
- puts(*argument);
- my_free((char*) load_default_groups,MYF(0));
- free_defaults(arguments);
-
- exit(0);
-}
diff --git a/include/Attic/config-win32.h b/include/Attic/config-win32.h
deleted file mode 100755
index e441749e038..00000000000
--- a/include/Attic/config-win32.h
+++ /dev/null
@@ -1,247 +0,0 @@
-/* Defines for Win32 to make it compatible for MySQL */
-
-#include <sys/locking.h>
-#include <windows.h>
-#include <math.h> /* Because of rint() */
-#include <fcntl.h>
-#include <io.h>
-#include <malloc.h>
-
-#ifdef __NT__
-#define SYSTEM_TYPE "NT"
-#else
-#define SYSTEM_TYPE "Win95/Win98"
-#endif
-#define MACHINE_TYPE "i586" /* Define to machine type name */
-#ifndef __WIN32__
-#define __WIN32__ /* To make it easier in VC++ */
-#endif
-
-/* File and lock constants */
-#define O_SHARE 0x1000 /* Open file in sharing mode */
-#ifdef __BORLANDC__
-#define F_RDLCK LK_NBLCK /* read lock */
-#define F_WRLCK LK_NBRLCK /* write lock */
-#define F_UNLCK LK_UNLCK /* remove lock(s) */
-#else
-#define F_RDLCK _LK_NBLCK /* read lock */
-#define F_WRLCK _LK_NBRLCK /* write lock */
-#define F_UNLCK _LK_UNLCK /* remove lock(s) */
-#endif
-
-#define F_EXCLUSIVE 1 /* We have only exclusive locking */
-#define F_TO_EOF (INT_MAX32/2) /* size for lock of all file */
-#define F_OK 0 /* parameter to access() */
-
-#define S_IROTH S_IREAD /* for my_lib */
-
-#ifdef __BORLANDC__
-#define FILE_BINARY O_BINARY /* my_fopen in binary mode */
-#define O_TEMPORARY 0
-#define O_SHORT_LIVED 0
-#define SH_DENYNO _SH_DENYNO
-#else
-#define O_BINARY _O_BINARY /* compability with MSDOS */
-#define FILE_BINARY _O_BINARY /* my_fopen in binary mode */
-#define O_TEMPORARY _O_TEMPORARY
-#define O_SHORT_LIVED _O_SHORT_LIVED
-#define SH_DENYNO _SH_DENYNO
-#endif
-#define NO_OPEN_3 /* For my_create() */
-
-#define SIGQUIT SIGTERM /* No SIGQUIT */
-
-#undef _REENTRANT /* Crashes something for win32 */
-
-#define LONGLONG_MIN ((__int64) 0x8000000000000000)
-#define LONGLONG_MAX ((__int64) 0x7FFFFFFFFFFFFFFF)
-#define LL(A) ((__int64) A)
-
-/* Type information */
-
-typedef unsigned short ushort;
-typedef unsigned int uint;
-typedef unsigned int size_t;
-typedef unsigned __int64 ulonglong; /* Microsofts 64 bit types */
-typedef __int64 longlong;
-typedef int sigset_t;
-#define longlong_defined
-/* off_t should not be __int64 because of conflicts in header files;
- Use my_off_t or os_off_t instead */
-typedef long off_t;
-typedef __int64 os_off_t;
-
-#define Socket_defined
-#define my_socket SOCKET
-#define bool BOOL
-#define SIGPIPE SIGINT
-#define RETQSORTTYPE void
-#define QSORT_TYPE_IS_VOID
-#define RETSIGTYPE void
-#define SOCKET_SIZE_TYPE int
-#define my_socket_defined
-#define bool_defined
-#define byte_defined
-#define HUGE_PTR
-#define STDCALL __stdcall /* Used by libmysql.dll */
-
-#ifndef UNDEF_THREAD_HACK
-#define THREAD
-#endif
-#define VOID_SIGHANDLER
-#define SIZEOF_CHAR 1
-#define SIZEOF_LONG 4
-#define SIZEOF_LONG_LONG 8
-#define SIZEOF_OFF_T 8
-#define HAVE_BROKEN_NETINET_INCLUDES
-#ifdef __NT__
-#define HAVE_NAMED_PIPE /* We can only create pipes on NT */
-#endif
-
-/* Convert some simple functions to Posix */
-
-#define sigset(A,B) signal((A),(B))
-#define finite(A) _finite(A)
-#define sleep(A) Sleep((A)*1000)
-
-#ifndef __BORLANDC__
-#define access(A,B) _access(A,B)
-#endif
-
-#if defined(__cplusplus)
-
-inline double rint(double nr)
-{
- double f = floor(nr);
- double c = ceil(nr);
- return (((c-nr) >= (nr-f)) ? f :c);
-}
-
-inline double ulonglong2double(ulonglong value)
-{
- longlong nr=(longlong) value;
- if (nr >= 0)
- return (double) nr;
- return (18446744073709551616.0 + (double) nr);
-}
-
-#define my_off_t2double(A) ulonglong2double(A)
-#else
-#define inline __inline
-#endif
-
-#if SIZEOF_OFF_T > 4
-#define lseek(A,B,C) _lseeki64((A),(longlong) (B),(C))
-#define tell(A) _telli64(A)
-#endif
-
-#define STACK_DIRECTION -1
-
-/* Optimized store functions for Intel x86 */
-
-#define sint2korr(A) (*((int16 *) (A)))
-#define sint3korr(A) ((int32) ((((uchar) (A)[2]) & 128) ? \
- (((uint32) 255L << 24) | \
- (((uint32) (uchar) (A)[2]) << 16) |\
- (((uint32) (uchar) (A)[1]) << 8) | \
- ((uint32) (uchar) (A)[0])) : \
- (((uint32) (uchar) (A)[2]) << 16) |\
- (((uint32) (uchar) (A)[1]) << 8) | \
- ((uint32) (uchar) (A)[0])))
-#define sint4korr(A) (*((long *) (A)))
-#define uint2korr(A) (*((uint16 *) (A)))
-#define uint3korr(A) (long) (*((unsigned long *) (A)) & 0xFFFFFF)
-#define uint4korr(A) (*((unsigned long *) (A)))
-#define uint5korr(A) ((ulonglong)(((uint32) ((uchar) (A)[0])) +\
- (((uint32) ((uchar) (A)[1])) << 8) +\
- (((uint32) ((uchar) (A)[2])) << 16) +\
- (((uint32) ((uchar) (A)[3])) << 24)) +\
- (((ulonglong) ((uchar) (A)[4])) << 32))
-#define uint8korr(A) (*((ulonglong *) (A)))
-#define sint8korr(A) (*((longlong *) (A)))
-#define int2store(T,A) *((uint16*) (T))= (uint16) (A)
-#define int3store(T,A) { *(T)= (uchar) ((A));\
- *(T+1)=(uchar) (((uint) (A) >> 8));\
- *(T+2)=(uchar) (((A) >> 16)); }
-#define int4store(T,A) *((long *) (T))= (long) (A)
-#define int5store(T,A) { *(T)= (uchar)((A));\
- *((T)+1)=(uchar) (((A) >> 8));\
- *((T)+2)=(uchar) (((A) >> 16));\
- *((T)+3)=(uchar) (((A) >> 24)); \
- *((T)+4)=(uchar) (((A) >> 32)); }
-#define int8store(T,A) *((ulonglong *) (T))= (ulonglong) (A)
-
-#define doubleget(V,M) { *((long *) &V) = *((long*) M); \
- *(((long *) &V)+1) = *(((long*) M)+1); }
-#define doublestore(T,V) { *((long *) T) = *((long*) &V); \
- *(((long *) T)+1) = *(((long*) &V)+1); }
-#define float4get(V,M) { *((long *) &(V)) = *((long*) (M)); }
-#define float8get(V,M) doubleget((V),(M))
-#define float4store(V,M) memcpy((byte*) V,(byte*) (&M),sizeof(float))
-#define float8store(V,M) doublestore((V),(M))
-
-
-#define HAVE_PERROR
-#define HAVE_VFPRINT
-#define HAVE_CHSIZE /* System has chsize() function */
-#define HAVE_RENAME /* Have rename() as function */
-#define HAVE_BINARY_STREAMS /* Have "b" flag in streams */
-#define HAVE_LONG_JMP /* Have long jump function */
-#define HAVE_LOCKING /* have locking() call */
-#define HAVE_ERRNO_AS_DEFINE /* errno is a define */
-#define HAVE_STDLIB /* everything is include in this file */
-#define HAVE_MEMCPY
-#define HAVE_MEMMOVE
-#define HAVE_GETCWD
-#define HAVE_TELL
-#define HAVE_TZNAME
-#define HAVE_PUTENV
-#define HAVE_SELECT
-#define HAVE_SETLOCALE
-#define HAVE_SOCKET /* Giangi */
-#define HAVE_FLOAT_H
-#define HAVE_LIMITS_H
-#define HAVE_STDDEF_H
-#define HAVE_RINT /* defined in this file */
-#define NO_FCNTL_NONBLOCK /* No FCNTL */
-#define HAVE_ALLOCA
-#define HAVE_COMPRESS
-
-#ifdef _MSC_VER
-#define HAVE_LDIV /* The optimizer breaks in zortech for ldiv */
-#define HAVE_ANSI_INCLUDE
-#define HAVE_SYS_UTIME_H
-#define HAVE_STRTOUL
-#endif
-#define my_reinterpret_cast(A) reinterpret_cast <A>
-#define my_const_cast(A) const_cast<A>
-
-/* MYSQL OPTIONS */
-
-#ifdef _CUSTOMCONFIG_
-#include <custom_conf.h>
-#else
-#define DEFAULT_MYSQL_HOME "c:\\mysql"
-#define PACKAGE "mysql"
-#define DEFAULT_BASEDIR "C:\\"
-#define SHAREDIR "share\\"
-#define DEFAULT_CHARSET_HOME "C:\\"
-#endif
-
-/* File name handling */
-
-#define FN_LIBCHAR '\\'
-#define FN_ROOTDIR "\\"
-#define FN_NETWORK_DRIVES /* Uses \\ to indicate network drives */
-#define FN_NO_CASE_SENCE /* Files are not case-sensitive */
-#define FN_LOWER_CASE TRUE /* Files are represented in lower case */
-#define MY_NFILE 127 /* This is only used to save filenames */
-
-
-#define thread_safe_increment(V,L) InterlockedIncrement((long*) &(V))
-/* The following is only used for statistics, so it should be good enough */
-#ifdef __NT__ /* This should also work on Win98 but .. */
-#define thread_safe_add(V,C,L) InterlockedExchangeAdd((long*) &(V),(C))
-#else
-#define thread_safe_add(V,C,L) InterlockedExchange((long*) &(V),(V)+(C))
-#endif
diff --git a/include/Attic/m_ctype.h.in b/include/Attic/m_ctype.h.in
deleted file mode 100644
index ea7782987e3..00000000000
--- a/include/Attic/m_ctype.h.in
+++ /dev/null
@@ -1,231 +0,0 @@
-/* Copyright (C) 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- For a more info consult the file COPYRIGHT distributed with this file */
-/*
- A better inplementation of the UNIX ctype(3) library.
- Notes: global.h should be included before ctype.h
-*/
-
-#ifndef _m_ctype_h
-#define _m_ctype_h
-
-#define MY_CHARSET_UNDEFINED 0
-#define MY_CHARSET_BIG5 1
-#define MY_CHARSET_CZECH 2
-#define MY_CHARSET_DEC8 3
-#define MY_CHARSET_DOS 4
-#define MY_CHARSET_GERMAN1 5
-#define MY_CHARSET_HP8 6
-#define MY_CHARSET_KOI8_RU 7
-#define MY_CHARSET_LATIN1 8
-#define MY_CHARSET_LATIN2 9
-#define MY_CHARSET_SWE7 10
-#define MY_CHARSET_USA7 11
-#define MY_CHARSET_UJIS 12
-#define MY_CHARSET_SJIS 13
-#define MY_CHARSET_CP1251 14
-#define MY_CHARSET_DANISH 15
-#define MY_CHARSET_HEBREW 16
-#define MY_CHARSET_WIN1251 17
-#define MY_CHARSET_TIS620 18
-#define MY_CHARSET_EUC_KR 19
-#define MY_CHARSET_ESTONIA 20
-#define MY_CHARSET_HUNGARIAN 21
-#define MY_CHARSET_KOI8_UKR 22
-#define MY_CHARSET_WIN1251UKR 23
-#define MY_CHARSET_GB2312 24
-#define MY_CHARSET_GREEK 25
-#define MY_CHARSET_WIN1250 26
-#define MY_CHARSET_CROAT 27
-#define MY_CHARSET_GBK 28
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __WIN32__
-#include <ctype.h>
-#endif
-/* Don't include std ctype.h when this is included */
-#define _CTYPE_H
-#define _CTYPE_INCLUDED
-#define __CTYPE_INCLUDED
-#define _CTYPE_USING /* Don't put names in global namespace. */
-
-#ifndef CTYPE_LIBRARY
-#define EXT extern
-#define D(x)
-#else
-#define EXT
-#define D(x) = x
-#endif
-
-#define _U 01 /* Upper case */
-#define _L 02 /* Lower case */
-#define _N 04 /* Numeral (digit) */
-#define _S 010 /* Spacing character */
-#define _P 020 /* Punctuation */
-#define _C 040 /* Control character */
-#define _B 0100 /* Blank */
-#define _X 0200 /* heXadecimal digit */
-
-extern uchar NEAR ctype_@mystrings_charset@[];
-extern uchar NEAR to_upper_@mystrings_charset@[];
-extern uchar NEAR to_lower_@mystrings_charset@[];
-extern uchar NEAR sort_order_@mystrings_charset@[];
-
-#define my_ctype ctype_@mystrings_charset@
-#define my_to_upper to_upper_@mystrings_charset@
-#define my_to_lower to_lower_@mystrings_charset@
-#define my_sort_order sort_order_@mystrings_charset@
-
-#ifndef __WIN32__
-#define _toupper(c) (char) my_to_upper[(uchar) (c)]
-#define _tolower(c) (char) my_to_lower[(uchar) (c)]
-#define toupper(c) (char) my_to_upper[(uchar) (c)]
-#define tolower(c) (char) my_to_lower[(uchar) (c)]
-
-#define isalpha(c) ((my_ctype+1)[(uchar) (c)] & (_U | _L))
-#define isupper(c) ((my_ctype+1)[(uchar) (c)] & _U)
-#define islower(c) ((my_ctype+1)[(uchar) (c)] & _L)
-#define isdigit(c) ((my_ctype+1)[(uchar) (c)] & _N)
-#define isxdigit(c) ((my_ctype+1)[(uchar) (c)] & _X)
-#define isalnum(c) ((my_ctype+1)[(uchar) (c)] & (_U | _L | _N))
-#define isspace(c) ((my_ctype+1)[(uchar) (c)] & _S)
-#define ispunct(c) ((my_ctype+1)[(uchar) (c)] & _P)
-#define isprint(c) ((my_ctype+1)[(uchar) (c)] & (_P | _U | _L | _N | _B))
-#define isgraph(c) ((my_ctype+1)[(uchar) (c)] & (_P | _U | _L | _N))
-#define iscntrl(c) ((my_ctype+1)[(uchar) (c)] & _C)
-#define isascii(c) (!((c) & ~0177))
-#define toascii(c) ((c) & 0177)
-
-#ifdef ctype
-#undef ctype
-#endif /* ctype */
-
-#endif /* __WIN32__ */
-
-/* Some macros that should be cleaned up a little */
-#define isvar(c) (isalnum(c) || (c) == '_')
-#define isvar_start(c) (isalpha(c) || (c) == '_')
-#define tocntrl(c) ((c) & 31)
-#define toprint(c) ((c) | 64)
-
-/* Support for Japanese(UJIS) characters, by tommy@valley.ne.jp */
-#if MY_CHARSET_CURRENT == MY_CHARSET_UJIS
-#define USE_MB
-#define USE_MB_IDENT
-#define isujis(c) ((0xa1<=((c)&0xff) && ((c)&0xff)<=0xfe))
-#define iskata(c) ((0xa1<=((c)&0xff) && ((c)&0xff)<=0xdf))
-#define isujis_ss2(c) (((c)&0xff) == 0x8e)
-#define isujis_ss3(c) (((c)&0xff) == 0x8f)
-#define ismbchar(p, end) ((*(uchar*)(p)<0x80)? 0:\
- isujis(*(p)) && (end)-(p)>1 && isujis(*((p)+1))? 2:\
- isujis_ss2(*(p)) && (end)-(p)>1 && iskata(*((p)+1))? 2:\
- isujis_ss3(*(p)) && (end)-(p)>2 && isujis(*((p)+1)) && isujis(*((p)+2))? 3:\
- 0)
-#define ismbhead(c) (isujis(c) || isujis_ss2(c) || isujis_ss3(c))
-#define mbcharlen(c) (isujis(c)? 2: isujis_ss2(c)? 2: isujis_ss3(c)? 3: 0)
-#define MBMAXLEN 3
-#endif
-
-/* Support for Japanese(SJIS) characters, by tommy@valley.ne.jp */
-#if MY_CHARSET_CURRENT == MY_CHARSET_SJIS
-#define USE_MB
-#define USE_MB_IDENT
-#define issjishead(c) ((0x81<=((c)&0xff) && ((c)&0xff)<=0x9f) || (0xe0<=((c)&0xff) && ((c)&0xff)<=0xfc))
-#define issjistail(c) ((0x40<=((c)&0xff) && ((c)&0xff)<=0x7e) || (0x80<=((c)&0xff) && ((c)&0xff)<=0xfc))
-#define ismbchar(p, end) (issjishead(*(p)) && (end)-(p)>1 && issjistail(*((p)+1))? 2: 0)
-#define ismbhead(c) issjishead(c)
-#define mbcharlen(c) (issjishead(c)? 2: 0)
-#define MBMAXLEN 2
-#endif
-
-/* Support for Chinese(BIG5) characters, by jou@nematic.ieo.nctu.edu.tw
- modified by Wei He (hewei@mail.ied.ac.cn) */
-
-#if MY_CHARSET_CURRENT == MY_CHARSET_BIG5
-#define USE_MB
-#define USE_MB_IDENT
-#define isbig5head(c) (0xa1<=(uchar)(c) && (uchar)(c)<=0xf9)
-#define isbig5tail(c) ((0x40<=(uchar)(c) && (uchar)(c)<=0x7e) || \
- (0xa1<=(uchar)(c) && (uchar)(c)<=0xfe))
-#define ismbchar(p, end) (isbig5head(*(p)) && (end)-(p)>1 && isbig5tail(*((p)+1))? 2: 0)
-#define ismbhead(c) isbig5head(c)
-#define mbcharlen(c) (isbig5head(c)? 2: 0)
-#define MBMAXLEN 2
-#
-#undef USE_STRCOLL
-#define USE_STRCOLL
-#endif
-
-/* Support for Chinese(GB2312) characters, by Miles Tsai (net-bull@126.com)
- modified by Wei He (hewei@mail.ied.ac.cn) */
-
-#if MY_CHARSET_CURRENT == MY_CHARSET_GB2312
-#define USE_MB
-#define USE_MB_IDENT
-#define isgb2312head(c) (0xa1<=(uchar)(c) && (uchar)(c)<=0xf7)
-#define isgb2312tail(c) (0xa1<=(uchar)(c) && (uchar)(c)<=0xfe)
-#define ismbchar(p, end) (isgb2312head(*(p)) && (end)-(p)>1 && isgb2312tail(*((p)+1))? 2: 0)
-#define ismbhead(c) isgb2312head(c)
-#define mbcharlen(c) (isgb2312head(c)? 2:0)
-#define MBMAXLEN 2
-#endif
-
-/* Support for Chinese(GBK) characters, by hewei@mail.ied.ac.cn */
-
-#if MY_CHARSET_CURRENT == MY_CHARSET_GBK
-#define USE_MB
-#define USE_MB_IDENT
-#define isgbkhead(c) (0x81<=(uchar)(c) && (uchar)(c)<=0xfe)
-#define isgbktail(c) ((0x40<=(uchar)(c) && (uchar)(c)<=0x7e) || \
- (0x80<=(uchar)(c) && (uchar)(c)<=0xfe))
-#define ismbchar(p, end) (isgbkhead(*(p)) && (end)-(p)>1 && isgbktail(*((p)+1))? 2: 0)
-#define ismbhead(c) isgbkhead(c)
-#define mbcharlen(c) (isgbkhead(c)? 2:0)
-#define MBMAXLEN 2
-#undef USE_STRCOLL
-#define USE_STRCOLL
-#endif
-
-/* Define, how much will the string grow under strxfrm */
-#if MY_CHARSET_CURRENT == MY_CHARSET_CZECH
-#undef USE_STRCOLL
-#define USE_STRCOLL
-#endif
-#if MY_CHARSET_CURRENT == MY_CHARSET_TIS620
-#undef USE_STRCOLL
-#define USE_STRCOLL
-#define USE_TIS620
-#include "t_ctype.h"
-#endif
-
-/* Support for Korean(EUC_KR) characters, by powerm90@tinc.co.kr and mrpark@tinc.co.kr */
-#if MY_CHARSET_CURRENT == MY_CHARSET_EUC_KR
-#define USE_MB
-#define USE_MB_IDENT
-#define iseuc_kr(c) ((0xa1<=(uchar)(c) && (uchar)(c)<=0xfe))
-#define ismbchar(p, end) ((*(uchar*)(p)<0x80)? 0:\
- iseuc_kr(*(p)) && (end)-(p)>1 && iseuc_kr(*((p)+1))? 2:\
- 0)
-#define ismbhead(c) (iseuc_kr(c))
-#define mbcharlen(c) (iseuc_kr(c) ? 2 : 0)
-#define MBMAXLEN 2
-#endif
-
-#ifdef USE_STRCOLL
-extern uint MY_STRXFRM_MULTIPLY;
-extern int my_strnxfrm(unsigned char *, unsigned char *, int, int);
-extern int my_strnncoll(const unsigned char *, int, const unsigned char *, int);
-extern int my_strxfrm(unsigned char *, unsigned char *, int);
-extern int my_strcoll(const unsigned char *, const unsigned char *);
-extern my_bool my_like_range(const char *ptr,uint ptr_length,pchar escape,
- uint res_length, char *min_str,char *max_str,
- uint *min_length,uint *max_length);
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _m_ctype_h */
diff --git a/include/Attic/mysql_com.h.in b/include/Attic/mysql_com.h.in
deleted file mode 100755
index aaf9f3f475f..00000000000
--- a/include/Attic/mysql_com.h.in
+++ /dev/null
@@ -1,216 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/*
-** Common definition between mysql server & client
-*/
-
-#ifndef _mysql_com_h
-#define _mysql_com_h
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define NAME_LEN 64 /* Field/table name length */
-#define HOSTNAME_LENGTH 60
-#define USERNAME_LENGTH 16
-
-#define LOCAL_HOST "localhost"
-#define LOCAL_HOST_NAMEDPIPE "."
-
-#ifndef _CUSTOMCONFIG_
-#define MYSQL_PORT @MYSQL_TCP_PORT@ /* Alloced by ISI for MySQL */
-#else
-#include "custom_conf.h"
-#endif
-
-#define MYSQL_UNIX_ADDR "@MYSQL_UNIX_ADDR@"
-#if defined(__EMX__) || defined(__OS2__)
-#undef MYSQL_UNIX_ADDR
-#define MYSQL_OS2_ADDR "\\socket\\MySQL"
-#define MYSQL_UNIX_ADDR MYSQL_OS2_ADDR
-#endif
-#if defined(__WIN32__) && !defined( _CUSTOMCONFIG_)
-#define MYSQL_NAMEDPIPE "MySQL"
-#define MYSQL_SERVICENAME "MySql"
-#endif /* __WIN32__ */
-
-enum enum_server_command {COM_SLEEP,COM_QUIT,COM_INIT_DB,COM_QUERY,
- COM_FIELD_LIST,COM_CREATE_DB,COM_DROP_DB,COM_REFRESH,
- COM_SHUTDOWN,COM_STATISTICS,
- COM_PROCESS_INFO,COM_CONNECT,COM_PROCESS_KILL,
- COM_DEBUG,COM_PING,COM_TIME,COM_DELAYED_INSERT,
- COM_CHANGE_USER, COM_BINLOG_DUMP};
-
-#define NOT_NULL_FLAG 1 /* Field can't be NULL */
-#define PRI_KEY_FLAG 2 /* Field is part of a primary key */
-#define UNIQUE_KEY_FLAG 4 /* Field is part of a unique key */
-#define MULTIPLE_KEY_FLAG 8 /* Field is part of a key */
-#define BLOB_FLAG 16 /* Field is a blob */
-#define UNSIGNED_FLAG 32 /* Field is unsigned */
-#define ZEROFILL_FLAG 64 /* Field is zerofill */
-#define BINARY_FLAG 128
-/* The following are only sent to new clients */
-#define ENUM_FLAG 256 /* field is an enum */
-#define AUTO_INCREMENT_FLAG 512 /* field is a autoincrement field */
-#define TIMESTAMP_FLAG 1024 /* Field is a timestamp */
-#define SET_FLAG 2048 /* field is a set */
-#define PART_KEY_FLAG 16384 /* Intern; Part of some key */
-#define GROUP_FLAG 32768 /* Intern: Group field */
-#define UNIQUE_FLAG 65536 /* Intern: Used by sql_yacc */
-
-#define REFRESH_GRANT 1 /* Refresh grant tables */
-#define REFRESH_LOG 2 /* Start on new log file */
-#define REFRESH_TABLES 4 /* close all tables */
-#define REFRESH_HOSTS 8 /* Flush host cache */
-#define REFRESH_STATUS 16 /* Flush status variables */
-#define REFRESH_FAST 32768 /* Intern flag */
-
-#define CLIENT_LONG_PASSWORD 1 /* new more secure passwords */
-#define CLIENT_FOUND_ROWS 2 /* Found instead of affected rows */
-#define CLIENT_LONG_FLAG 4 /* Get all column flags */
-#define CLIENT_CONNECT_WITH_DB 8 /* One can specify db on connect */
-#define CLIENT_NO_SCHEMA 16 /* Don't allow database.table.column */
-#define CLIENT_COMPRESS 32 /* Can use compression protocol */
-#define CLIENT_ODBC 64 /* Odbc client */
-#define CLIENT_LOCAL_FILES 128 /* Can use LOAD DATA LOCAL */
-#define CLIENT_IGNORE_SPACE 256 /* Ignore spaces before '(' */
-#define CLIENT_CHANGE_USER 512 /* Support the mysql_change_user() */
-#define CLIENT_INTERACTIVE 1024 /* This is an interactive client */
-#define CLIENT_SSL 2048 /* Switch to SSL after handshake */
-#define CLIENT_IGNORE_SIGPIPE 4096 /* IGNORE sigpipes */
-
-#define MYSQL_ERRMSG_SIZE 200
-#define NET_READ_TIMEOUT 30 /* Timeout on read */
-#define NET_WRITE_TIMEOUT 60 /* Timeout on write */
-#define NET_WAIT_TIMEOUT 8*60*60 /* Wait for new query */
-
-#ifndef Vio_defined
-#define Vio_defined
-#ifdef HAVE_VIO
-class Vio; /* Fill Vio class in C++ */
-#else
-struct st_vio; /* Only C */
-typedef struct st_vio Vio;
-#endif
-#endif
-
-typedef struct st_net {
- Vio* vio;
- my_socket fd; /* For Perl DBI/dbd */
- int fcntl;
- unsigned char *buff,*buff_end,*write_pos,*read_pos;
- char last_error[MYSQL_ERRMSG_SIZE];
- unsigned int last_errno,max_packet,timeout,pkt_nr;
- my_bool error,return_errno,compress;
-
- unsigned long remain_in_buf,length, buf_length, where_b;
- my_bool more;
- char save_char;
-} NET;
-
-#define packet_error ((unsigned int) -1)
-
-enum enum_field_types { FIELD_TYPE_DECIMAL, FIELD_TYPE_TINY,
- FIELD_TYPE_SHORT, FIELD_TYPE_LONG,
- FIELD_TYPE_FLOAT, FIELD_TYPE_DOUBLE,
- FIELD_TYPE_NULL, FIELD_TYPE_TIMESTAMP,
- FIELD_TYPE_LONGLONG,FIELD_TYPE_INT24,
- FIELD_TYPE_DATE, FIELD_TYPE_TIME,
- FIELD_TYPE_DATETIME, FIELD_TYPE_YEAR,
- FIELD_TYPE_NEWDATE,
- FIELD_TYPE_ENUM=247,
- FIELD_TYPE_SET=248,
- FIELD_TYPE_TINY_BLOB=249,
- FIELD_TYPE_MEDIUM_BLOB=250,
- FIELD_TYPE_LONG_BLOB=251,
- FIELD_TYPE_BLOB=252,
- FIELD_TYPE_VAR_STRING=253,
- FIELD_TYPE_STRING=254
-};
-
-#define FIELD_TYPE_CHAR FIELD_TYPE_TINY /* For compability */
-#define FIELD_TYPE_INTERVAL FIELD_TYPE_ENUM /* For compability */
-
-extern unsigned long max_allowed_packet;
-extern unsigned long net_buffer_length;
-
-#define net_new_transaction(net) ((net)->pkt_nr=0)
-
-int my_net_init(NET *net, Vio* vio);
-void net_end(NET *net);
-void net_clear(NET *net);
-int net_flush(NET *net);
-int my_net_write(NET *net,const char *packet,unsigned long len);
-int net_write_command(NET *net,unsigned char command,const char *packet,
- unsigned long len);
-int net_real_write(NET *net,const char *packet,unsigned long len);
-unsigned int my_net_read(NET *net);
-
-struct rand_struct {
- unsigned long seed1,seed2,max_value;
- double max_value_dbl;
-};
-
- /* The following is for user defined functions */
-
-enum Item_result {STRING_RESULT,REAL_RESULT,INT_RESULT};
-
-typedef struct st_udf_args
-{
- unsigned int arg_count; /* Number of arguments */
- enum Item_result *arg_type; /* Pointer to item_results */
- char **args; /* Pointer to argument */
- unsigned long *lengths; /* Length of string arguments */
- char *maybe_null; /* Set to 1 for all maybe_null args */
-} UDF_ARGS;
-
- /* This holds information about the result */
-
-typedef struct st_udf_init
-{
- my_bool maybe_null; /* 1 if function can return NULL */
- unsigned int decimals; /* for real functions */
- unsigned int max_length; /* For string functions */
- char *ptr; /* free pointer for function data */
- my_bool const_item; /* 0 if result is independent of arguments */
-} UDF_INIT;
-
- /* Constants when using compression */
-#define NET_HEADER_SIZE 4 /* standard header size */
-#define COMP_HEADER_SIZE 3 /* compression header extra size */
-
- /* Prototypes to password functions */
-
-void randominit(struct rand_struct *,unsigned long seed1,
- unsigned long seed2);
-double rnd(struct rand_struct *);
-void make_scrambled_password(char *to,const char *password);
-void get_salt_from_password(unsigned long *res,const char *password);
-void make_password_from_salt(char *to, unsigned long *hash_res);
-char *scramble(char *to,const char *message,const char *password,
- my_bool old_ver);
-my_bool check_scramble(const char *, const char *message,
- unsigned long *salt,my_bool old_ver);
-char *get_tty_password(char *opt_message);
-void hash_password(unsigned long *result, const char *password);
-
-/* Some other useful functions */
-
-void my_init(void);
-void load_defaults(const char *conf_file, const char **groups,
- int *argc, char ***argv);
-
-#define NULL_LENGTH ((unsigned long) ~0) /* For net_store_length */
-
-#ifdef __WIN32__
-#define socket_errno WSAGetLastError()
-#else
-#define socket_errno errno
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-#endif
diff --git a/myisam/Attic/ft_global.h b/myisam/Attic/ft_global.h
deleted file mode 100644
index c8d0734fed3..00000000000
--- a/myisam/Attic/ft_global.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-
-/* Written by Sergei A. Golubchik, who has a shared copyright to this code */
-
-/* some definitions for full-text indices */
-
-/* #include "myisam.h" */
-
-#ifndef _ft_global_h
-#define _ft_global_h
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define FT_QUERY_MAXLEN 1024
-
-typedef struct ft_doc_rec {
- my_off_t dpos;
- double weight;
-} FT_DOC;
-
-typedef struct st_ft_doclist {
- int ndocs;
- int curdoc;
- void *info; /* actually (MI_INFO *) but don't want to include myisam.h */
- FT_DOC doc[1];
-} FT_DOCLIST;
-
-int ft_init_stopwords(const char **);
-
-FT_DOCLIST * ft_init_search(MI_INFO *, uint, byte *, uint, bool);
-double ft_read_next(FT_DOCLIST *, char *);
-#define ft_close_search(handler) my_free(((gptr)(handler)),MYF(0))
-
-#ifdef __cplusplus
-}
-#endif
-#endif
diff --git a/mysql-test/r/innobase.result b/mysql-test/r/innobase.result
index 6c45bfd810d..4e2c659bffb 100644
--- a/mysql-test/r/innobase.result
+++ b/mysql-test/r/innobase.result
@@ -445,3 +445,5 @@ i j
1 2
MIN(B) MAX(b)
1 1
+table type possible_keys key key_len ref rows Extra
+t1 range PRIMARY PRIMARY 4 NULL 1 where used
diff --git a/scripts/mysql_install_db.sh b/scripts/mysql_install_db.sh
index 3dbf7c50ad3..22516345512 100644
--- a/scripts/mysql_install_db.sh
+++ b/scripts/mysql_install_db.sh
@@ -80,6 +80,7 @@ then
bindir=@bindir@
execdir=@libexecdir@
elif test -d "$basedir/libexec"
+then
bindir="$basedir/bin"
execdir="$basedir/libexec"
else
diff --git a/sql/Attic/lex_hash.h b/sql/Attic/lex_hash.h
deleted file mode 100644
index 6e89119a3dc..00000000000
--- a/sql/Attic/lex_hash.h
+++ /dev/null
@@ -1,416 +0,0 @@
-/* This code is generated by program for seeking hash algorithms, copyright TcX Datakonsult AB */
-
-#include "lex.h"
-
-static uint16 char_table[] = {
-258,39835,4883,21845,23130,46003,12850,35980,514,65278,61937,7196,40863,26728,26985,9766,
-5654,23644,21331,17733,3341,25186,30069,1542,31354,39321,4626,52171,46260,57568,21588,14906,
-60652,20560,6939,39578,52428,10794,46517,40606,58596,17990,58339,24672,42148,60138,3598,5911,
-43947,37522,36494,1799,36751,30840,57311,34952,56540,27499,45232,41891,61423,38550,29812,24158,
-771,37779,57054,257,8224,64250,51657,16962,13878,20303,42662,6168,19275,20817,34438,44461,
-12336,48059,49087,28013,3855,16191,32896,26214,57825,38807,29298,35723,51400,12079,6682,25957,
-8738,37779,57054,257,8224,64250,51657,16962,13878,20303,42662,6168,19275,20817,34438,44461,
-12336,48059,49087,28013,3855,16191,32896,26214,57825,38807,29298,32639,11051,43690,2313,33924,
-16705,53970,4112,24415,30583,17476,45746,7967,34695,35466,25700,6425,29555,59881,10537,37008,
-7710,2827,62965,11565,26471,43433,34181,30326,13364,29041,54998,47802,52685,63993,2056,51914,
-31097,44718,48830,50372,23387,62194,19789,19532,53456,62451,16448,54741,63736,18761,10023,3084,
-20046,31868,50629,15420,54484,42405,47288,31611,28270,47031,61680,65535,49344,23901,42919,48316,
-10280,55512,60395,51143,9252,53199,40349,56797,13621,11308,49601,36237,18247,15934,18504,46774,
-43176,11822,56283,28784,59624,39064,63479,19018,58853,65021,9509,8995,58082,5140,5397,15163,
-27242,22102,28527,22873,59367,47545,13107,60909,41120,24929,22616,49858,38036,17219,4369,64507,
-50115,62708,7453,41377,53713,33153,32382,59110,64764,50886,33410,8481,63222,41634,12593,56026
-};
-
-
-static uchar unique_length[] = {
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,3,1,2,0,
-0,5,5,13,9,7,6,6,6,7,1,4,5,7,5,7,
-8,3,12,10,6,7,4,5,0,5,1,0,0,0,0,0,
-0,5,5,13,9,7,6,6,6,7,1,4,5,7,5,7,
-8,3,12,10,6,7,4,5,0,5,1,0,1,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
-};
-
-
-static uint16 my_function_table[] = {
-32767,32767,32767,32767,32767,32767,32767,32767,102,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,282,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,297,32767,32767,202,382,126,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,169,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,306,152,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,354,32767,32767,32767,32767,32767,370,256,32767,
-32767,32767,32767,32767,32767,32767,355,32767,32767,32767,32767,361,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,313,32767,32767,32767,32767,32767,32767,
-14,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,315,
-32767,32767,32767,32767,32767,32767,32767,32767,42,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,189,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,27,32767,32767,32767,32767,32767,32767,32767,374,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,166,32767,32767,32767,32767,32767,32767,349,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-46,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,353,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,223,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-216,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,143,32767,32767,32767,32767,32767,32767,32767,
-32767,20,32767,32767,32767,140,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,125,32767,32767,32767,
-32767,224,32767,32767,32767,32767,267,32767,175,32767,32767,32767,
-246,32767,32767,32767,32767,32767,32767,109,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,324,32767,
-32767,32767,32767,32767,161,32767,21,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,11,32767,32767,32767,32767,32767,32767,32767,
-194,32767,32767,32767,32767,32767,32767,32767,32767,332,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,364,342,32767,
-32767,32767,32767,32767,32767,193,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,373,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,212,32767,32767,32767,32,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,54,
-67,32767,32767,32767,32767,32767,32767,32767,32767,287,32767,32767,
-32767,32767,32767,51,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,273,219,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,261,32767,32767,32767,32767,
-32767,123,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,198,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,233,32767,32767,32767,32767,32767,32767,32767,338,32767,32767,
-32767,32767,32767,32767,32767,236,32767,32767,32767,310,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,232,32767,32767,32767,32767,135,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,65,32767,32767,150,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,2,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,378,32767,32767,32767,32767,32767,107,32767,32767,32767,32767,
-32767,32767,32767,335,32767,358,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,188,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-254,32767,32767,146,32767,32767,32767,32767,32767,153,33,32767,
-32767,32767,32767,32767,32767,32767,242,32767,32767,32767,32767,32767,
-32767,32767,32767,226,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,167,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,104,32767,32767,
-32767,32767,32767,32767,32767,195,37,32767,32767,253,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,88,32767,32767,32767,32767,154,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,300,32767,32767,32767,330,314,326,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,259,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,134,32767,32767,32767,32767,341,
-32767,32767,32767,32767,32767,32767,281,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,316,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,22,32767,32767,32767,32767,32767,
-32767,32767,268,32767,32767,144,32767,32767,32767,32767,32767,32767,
-32767,239,165,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,200,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,351,87,32767,32767,255,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,180,32767,32767,32767,32767,32767,10,24,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,376,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,230,32767,32767,32767,32767,32767,303,44,217,
-32767,32767,32767,32767,32767,32767,32767,32767,317,32767,32767,32767,
-266,32767,58,32767,84,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,181,32767,381,32767,296,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,40,32767,32767,32767,32767,32767,133,196,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,263,32767,
-32767,32767,32767,32767,32767,182,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,28,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,307,32767,32767,
-32767,32767,3,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-174,298,32767,32767,32767,32767,362,32767,32767,32767,151,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,99,32767,112,
-32767,32767,15,32767,32767,32767,32767,32767,32767,32767,32767,129,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,76,32767,32767,32767,32767,93,32767,337,32767,32767,
-356,32767,32767,32767,328,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,91,32767,250,32767,32767,32767,32767,
-32767,32767,32767,32767,205,32767,32767,32767,32767,32767,32767,32767,
-32767,368,32767,1,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,38,32767,203,32767,176,32767,32767,32767,32767,
-32767,32767,208,32767,32767,32767,32767,32767,32767,32767,320,32767,
-156,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,277,32767,32767,32767,32767,32767,32767,
-32767,30,32767,32767,344,32767,32767,32767,32767,383,32767,32767,
-155,32767,32767,119,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,211,43,32767,32767,32767,32767,32767,141,32767,158,32767,
-32767,32767,32767,32767,283,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,280,32767,120,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,35,32767,32767,32767,32767,32767,347,32767,32767,
-32767,32767,318,32767,32767,32767,235,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,262,32767,32767,32767,32767,45,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,305,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,278,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,238,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,7,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,122,32767,19,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,288,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,206,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,139,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,56,32767,32767,32767,32767,106,32767,77,32767,32767,32767,
-32767,101,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,379,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,4,32767,32767,62,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,201,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,163,32767,32767,
-98,32767,32767,32767,32767,32767,32767,162,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,192,82,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,340,32767,32767,32767,145,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,184,32767,32767,32767,32767,32767,32767,173,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,301,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,149,32767,32767,32767,32767,32767,32767,32767,32767,279,32767,
-142,32767,32767,294,32767,32767,32767,32767,32767,32767,32767,333,
-32767,32767,32767,32767,32767,117,32767,32767,69,32767,32767,96,
-32767,32767,32767,286,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,73,32767,32767,32767,32767,
-32767,103,32767,164,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-92,32767,32767,32767,32767,32767,221,272,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,25,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,311,
-225,32767,207,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,295,32767,108,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,290,384,32767,32767,32767,32767,
-32767,32767,32767,32767,80,32767,346,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,366,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,128,32767,32767,
-32767,32767,32767,83,243,32767,32767,32767,270,32767,32767,118,
-32767,32767,249,32767,32767,241,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,229,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,86,32767,32767,260,50,32767,32767,227,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,23,32767,32767,32767,32767,32767,32767,309,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-371,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,114,32767,32767,32767,32767,32767,32767,
-365,13,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,352,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,178,289,32767,32767,32767,32767,32767,32767,
-32767,32767,81,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,60,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,105,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-168,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,350,32767,32767,32767,32767,
-276,32767,32767,32767,32767,32767,32767,32767,199,59,32767,32767,
-32767,32767,32767,32767,32767,322,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,339,32767,32767,32767,32767,
-32767,32767,32767,94,32767,32767,228,32767,32767,32767,32767,293,
-32767,32767,32767,55,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,244,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,66,32767,32767,32767,32767,258,357,32767,32767,32767,
-32767,8,32767,32767,32767,12,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,124,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-111,32767,32767,32767,32767,32767,63,32767,32767,32767,95,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,329,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,159,32767,32767,32767,32767,
-215,32767,32767,274,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,85,32767,6,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,312,113,32767,32767,32767,78,
-32767,323,18,32767,32767,32767,32767,32767,32767,369,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,90,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-325,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-210,32767,32767,32767,32767,32767,9,32767,32767,121,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,319,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,220,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,39,32767,32767,
-271,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,234,
-32767,32767,32767,367,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,363,0,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-204,177,32767,32767,32767,32767,32767,32767,32767,32767,148,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,284,252,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,222,32767,75,32767,32767,32767,32767,292,
-32767,32767,32767,32767,32767,32767,172,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,360,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,138,32767,32767,380,32767,359,32767,
-32767,32767,32767,32767,32767,79,32767,32767,32767,32767,248,32767,
-32767,32767,32767,32767,32767,32767,147,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,327,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,299,32767,32767,32767,32767,72,32767,32767,32767,
-32767,240,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-343,32767,32767,32767,32767,32767,137,32767,32767,32767,32767,32767,
-32767,32767,32767,130,32767,32767,32767,32767,32767,32767,32767,131,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,57,32767,5,32767,32767,32767,
-32767,32767,32767,291,32767,32767,32767,32767,32767,213,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,375,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,68,
-32767,32767,32767,32767,64,32767,32767,32767,32767,32767,32767,171,
-32767,32767,32767,49,32767,32767,32767,32767,32767,48,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,275,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,345,331,32767,32767,32767,32767,32767,157,32767,32767,32767,
-32767,32767,32767,32767,32767,190,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,74,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-334,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,179,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,264,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,53,32767,32767,
-32767,32767,32767,32767,209,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,245,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,61,32767,
-52,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,186,32767,41,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-70,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,247,32767,32767,32767,32767,136,36,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,31,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,336,32767,32767,32767,265,191,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,127,32767,32767,32767,32767,32767,32767,
-321,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,116,32767,32767,32767,32767,32767,32767,26,32767,32767,
-32767,32767,32767,32767,32767,32767,269,32767,32767,32767,32767,32767,
-100,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,183,34,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,372,32767,32767,32767,32767,32767,
-308,32767,32767,285,32767,32767,32767,32767,377,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,257,32767,32767,32767,32767,32767,97,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,89,32767,32767,302,160,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,170,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,110,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,16,32767,214,71,32767,32767,32767,
-32767,32767,32767,197,32767,32767,32767,32767,32767,32767,32767,17,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-237,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,187,32767,218,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,304,32767,32767,32767,32767,32767,32767,32767,32767,185,32767,
-348,32767,32767,32767,231,32767,32767,32767,32767,32767,251,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
-32767,132,32767,32767,32767,32767,32767,32767,32767,115,32767,32767,
-32767,29,32767,32767,32767,32767,32767,32767,32767,32767,32767,47,
-32767,32767,32767,32767,32767
-};
-
-
-/* t1= 45205 t2=3702303 type= 0 */
-
-inline SYMBOL *get_hash_symbol(const char *s,unsigned int length,bool function)
-{
- ulong idx = 2003+char_table[(uchar) *s];
- SYMBOL *sim;
- const char *start=s;
- int i=unique_length[(uchar) *s++];
- if (i > (int) length) i=(int) length;
- while (--i > 0)
- idx= (idx ^ (char_table[(uchar) *s++] + (idx << 7)));
- idx=my_function_table[(idx & 8388607) % 4133];
- if (idx >= 262)
- {
- if (!function || idx >= 32767) return (SYMBOL*) 0;
- sim=sql_functions + (idx - 262);
- }
- else
- sim=symbols + idx;
- if ((length != sim->length) || lex_casecmp(start,sim->name,length))
- return (SYMBOL *)0;
- return sim;
-}
diff --git a/sql/Attic/mini_client.c b/sql/Attic/mini_client.c
deleted file mode 100644
index 56a6de14742..00000000000
--- a/sql/Attic/mini_client.c
+++ /dev/null
@@ -1,783 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/*
- mini MySQL client to be included into the server to do server to server
- commincation by Sasha Pachev
-
- Note: all file-global symbols must begin with mc_ , even the static ones, just
- in case we decide to make them external at some point
- */
-
-#define DONT_USE_RAID
-#if defined(__WIN32__) || defined(WIN32)
-#include <winsock.h>
-#include <odbcinst.h>
-#endif
-#include <global.h>
-#include <my_sys.h>
-#include <mysys_err.h>
-#include <m_string.h>
-#include <m_ctype.h>
-#include "mysql.h"
-#include "mini_client.h"
-#include "mysql_version.h"
-#include "mysqld_error.h"
-#include "errmsg.h"
-#include <violite.h>
-#include <sys/stat.h>
-#include <signal.h>
-#ifdef HAVE_PWD_H
-#include <pwd.h>
-#endif
-#if !defined(MSDOS) && !defined(__WIN32__)
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <netdb.h>
-#ifdef HAVE_SELECT_H
-# include <select.h>
-#endif
-#ifdef HAVE_SYS_SELECT_H
-#include <sys/select.h>
-#endif
-#endif
-#ifdef HAVE_SYS_UN_H
-# include <sys/un.h>
-#endif
-#if defined(THREAD) && !defined(__WIN32__)
-#include <my_pthread.h> /* because of signal() */
-#endif
-#ifndef INADDR_NONE
-#define INADDR_NONE -1
-#endif
-
-
-static void mc_end_server(MYSQL *mysql);
-static int mc_sock_connect(File s, const struct sockaddr *name, uint namelen, uint to);
-static void mc_free_old_query(MYSQL *mysql);
-
-
-#define CLIENT_CAPABILITIES (CLIENT_LONG_PASSWORD | CLIENT_LONG_FLAG | CLIENT_LOCAL_FILES)
-
-#if defined(MSDOS) || defined(__WIN32__)
-#define ERRNO WSAGetLastError()
-#define perror(A)
-#else
-#include <sys/errno.h>
-#define ERRNO errno
-#define SOCKET_ERROR -1
-#define closesocket(A) close(A)
-#endif
-
-#ifdef __WIN32__
-static my_bool is_NT(void)
-{
- char *os=getenv("OS");
- return (os && !strcmp(os, "Windows_NT")) ? 1 : 0;
-}
-#endif
-
-/*
-** Create a named pipe connection
-*/
-
-#ifdef __WIN32__
-
-HANDLE create_named_pipe(NET *net, uint connect_timeout, char **arg_host,
- char **arg_unix_socket)
-{
- HANDLE hPipe=INVALID_HANDLE_VALUE;
- char szPipeName [ 257 ];
- DWORD dwMode;
- int i;
- my_bool testing_named_pipes=0;
- char *host= *arg_host, *unix_socket= *arg_unix_socket;
-
- if (!host || !strcmp(host,LOCAL_HOST))
- host=LOCAL_HOST_NAMEDPIPE;
-
- sprintf( szPipeName, "\\\\%s\\pipe\\%s", host, unix_socket);
- DBUG_PRINT("info",("Server name: '%s'. Named Pipe: %s",
- host, unix_socket));
-
- for (i=0 ; i < 100 ; i++) /* Don't retry forever */
- {
- if ((hPipe = CreateFile(szPipeName,
- GENERIC_READ | GENERIC_WRITE,
- 0,
- NULL,
- OPEN_EXISTING,
- 0,
- NULL )) != INVALID_HANDLE_VALUE)
- break;
- if (GetLastError() != ERROR_PIPE_BUSY)
- {
- net->last_errno=CR_NAMEDPIPEOPEN_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- /* wait for for an other instance */
- if (! WaitNamedPipe(szPipeName, connect_timeout*1000) )
- {
- net->last_errno=CR_NAMEDPIPEWAIT_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- }
- if (hPipe == INVALID_HANDLE_VALUE)
- {
- net->last_errno=CR_NAMEDPIPEOPEN_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- dwMode = PIPE_READMODE_BYTE | PIPE_WAIT;
- if ( !SetNamedPipeHandleState(hPipe, &dwMode, NULL, NULL) )
- {
- CloseHandle( hPipe );
- net->last_errno=CR_NAMEDPIPESETSTATE_ERROR;
- sprintf(net->last_error,ER(net->last_errno),host, unix_socket,
- (ulong) GetLastError());
- return INVALID_HANDLE_VALUE;
- }
- *arg_host=host ; *arg_unix_socket=unix_socket; /* connect arg */
- return (hPipe);
-}
-#endif
-
-
-/****************************************************************************
-** Init MySQL structure or allocate one
-****************************************************************************/
-
-MYSQL * STDCALL
-mc_mysql_init(MYSQL *mysql)
-{
- if (!mysql)
- {
- if (!(mysql=(MYSQL*) my_malloc(sizeof(*mysql),MYF(MY_WME | MY_ZEROFILL))))
- return 0;
- mysql->free_me=1;
- mysql->net.vio = 0;
- }
- else
- bzero((char*) (mysql),sizeof(*(mysql)));
-#ifdef __WIN32__
- mysql->options.connect_timeout=20;
-#endif
- return mysql;
-}
-
-/**************************************************************************
-** Shut down connection
-**************************************************************************/
-
-static void
-mc_end_server(MYSQL *mysql)
-{
- DBUG_ENTER("mc_end_server");
- if (mysql->net.vio != 0)
- {
- DBUG_PRINT("info",("Net: %s", vio_description(mysql->net.vio)));
- vio_delete(mysql->net.vio);
- mysql->net.vio= 0; /* Marker */
- }
- net_end(&mysql->net);
- mc_free_old_query(mysql);
- DBUG_VOID_RETURN;
-}
-
-static void mc_free_old_query(MYSQL *mysql)
-{
- DBUG_ENTER("mc_free_old_query");
- if (mysql->fields)
- free_root(&mysql->field_alloc);
- init_alloc_root(&mysql->field_alloc,8192); /* Assume rowlength < 8192 */
- mysql->fields=0;
- mysql->field_count=0; /* For API */
- DBUG_VOID_RETURN;
-}
-
-
-/****************************************************************************
-* A modified version of connect(). mc_sock_connect() allows you to specify
-* a timeout value, in seconds, that we should wait until we
-* derermine we can't connect to a particular host. If timeout is 0,
-* mc_sock_connect() will behave exactly like connect().
-*
-* Base version coded by Steve Bernacki, Jr. <steve@navinet.net>
-*****************************************************************************/
-
-static int mc_sock_connect(File s, const struct sockaddr *name, uint namelen, uint to)
-{
-#if defined(__WIN32__)
- return connect(s, (struct sockaddr*) name, namelen);
-#else
- int flags, res, s_err;
- size_socket s_err_size = sizeof(uint);
- fd_set sfds;
- struct timeval tv;
-
- /* If they passed us a timeout of zero, we should behave
- * exactly like the normal connect() call does.
- */
-
- if (to == 0)
- return connect(s, (struct sockaddr*) name, namelen);
-
- flags = fcntl(s, F_GETFL, 0); /* Set socket to not block */
-#ifdef O_NONBLOCK
- fcntl(s, F_SETFL, flags | O_NONBLOCK); /* and save the flags.. */
-#endif
-
- res = connect(s, (struct sockaddr*) name, namelen);
- s_err = errno; /* Save the error... */
- fcntl(s, F_SETFL, flags);
- if ((res != 0) && (s_err != EINPROGRESS))
- {
- errno = s_err; /* Restore it */
- return(-1);
- }
- if (res == 0) /* Connected quickly! */
- return(0);
-
- /* Otherwise, our connection is "in progress." We can use
- * the select() call to wait up to a specified period of time
- * for the connection to suceed. If select() returns 0
- * (after waiting howevermany seconds), our socket never became
- * writable (host is probably unreachable.) Otherwise, if
- * select() returns 1, then one of two conditions exist:
- *
- * 1. An error occured. We use getsockopt() to check for this.
- * 2. The connection was set up sucessfully: getsockopt() will
- * return 0 as an error.
- *
- * Thanks goes to Andrew Gierth <andrew@erlenstar.demon.co.uk>
- * who posted this method of timing out a connect() in
- * comp.unix.programmer on August 15th, 1997.
- */
-
- FD_ZERO(&sfds);
- FD_SET(s, &sfds);
- tv.tv_sec = (long) to;
- tv.tv_usec = 0;
- res = select(s+1, NULL, &sfds, NULL, &tv);
- if (res <= 0) /* Never became writable */
- return(-1);
-
- /* select() returned something more interesting than zero, let's
- * see if we have any errors. If the next two statements pass,
- * we've got an open socket!
- */
-
- s_err=0;
- if (getsockopt(s, SOL_SOCKET, SO_ERROR, (char*) &s_err, &s_err_size) != 0)
- return(-1);
-
- if (s_err)
- { /* getsockopt() could suceed */
- errno = s_err;
- return(-1); /* but return an error... */
- }
- return(0); /* It's all good! */
-#endif
-}
-
-/*****************************************************************************
-** read a packet from server. Give error message if socket was down
-** or packet is an error message
-*****************************************************************************/
-
-uint STDCALL
-mc_net_safe_read(MYSQL *mysql)
-{
- NET *net= &mysql->net;
- uint len=0;
-
- if (net->vio != 0)
- len=my_net_read(net);
-
- if (len == packet_error || len == 0)
- {
- DBUG_PRINT("error",("Wrong connection or packet. fd: %s len: %d",
- vio_description(net->vio),len));
- if(errno != EINTR)
- {
- mc_end_server(mysql);
- net->last_errno=CR_SERVER_LOST;
- strmov(net->last_error,ER(net->last_errno));
- }
- return(packet_error);
- }
- if (net->read_pos[0] == 255)
- {
- if (len > 3)
- {
- char *pos=(char*) net->read_pos+1;
- if (mysql->protocol_version > 9)
- { /* New client protocol */
- net->last_errno=uint2korr(pos);
- pos+=2;
- len-=2;
- if(!net->last_errno)
- net->last_errno = CR_UNKNOWN_ERROR;
- }
- else
- {
- net->last_errno=CR_UNKNOWN_ERROR;
- len--;
- }
- (void) strmake(net->last_error,(char*) pos,
- min(len,sizeof(net->last_error)-1));
- }
- else
- {
- net->last_errno=CR_UNKNOWN_ERROR;
- (void) strmov(net->last_error,ER(net->last_errno));
- }
- DBUG_PRINT("error",("Got error: %d (%s)", net->last_errno,
- net->last_error));
- return(packet_error);
- }
- return len;
-}
-
-
-char * STDCALL mc_mysql_error(MYSQL *mysql)
-{
- return (mysql)->net.last_error;
-}
-
-my_bool STDCALL mc_mysql_reconnect(MYSQL *mysql)
-{
- MYSQL tmp_mysql;
- DBUG_ENTER("mc_mysql_reconnect");
-
- mc_mysql_init(&tmp_mysql);
- tmp_mysql.options=mysql->options;
- if (!mc_mysql_connect(&tmp_mysql,mysql->host,mysql->user,mysql->passwd,
- mysql->db, mysql->port, mysql->unix_socket,
- mysql->client_flag))
- DBUG_RETURN(1);
- tmp_mysql.free_me=mysql->free_me;
- mysql->free_me=0;
- bzero((char*) &mysql->options,sizeof(&mysql->options));
- mc_mysql_close(mysql);
- *mysql=tmp_mysql;
- net_clear(&mysql->net);
- mysql->affected_rows= ~(my_ulonglong) 0;
- DBUG_RETURN(0);
-}
-
-
-
-int STDCALL
-mc_simple_command(MYSQL *mysql,enum enum_server_command command, const char *arg,
- uint length, my_bool skipp_check)
-{
- NET *net= &mysql->net;
- int result= -1;
-
- if (mysql->net.vio == 0)
- { /* Do reconnect if possible */
- if (mc_mysql_reconnect(mysql))
- {
- net->last_errno=CR_SERVER_GONE_ERROR;
- strmov(net->last_error,ER(net->last_errno));
- goto end;
- }
- }
- if (mysql->status != MYSQL_STATUS_READY)
- {
- strmov(net->last_error,ER(mysql->net.last_errno=CR_COMMANDS_OUT_OF_SYNC));
- goto end;
- }
-
- mysql->net.last_error[0]=0;
- mysql->net.last_errno=0;
- mysql->info=0;
- mysql->affected_rows= ~(my_ulonglong) 0;
- net_clear(net); /* Clear receive buffer */
- if (!arg)
- arg="";
-
- if (net_write_command(net,(uchar) command,arg,
- length ? length :strlen(arg)))
- {
- DBUG_PRINT("error",("Can't send command to server. Error: %d",errno));
- mc_end_server(mysql);
- if (mc_mysql_reconnect(mysql) ||
- net_write_command(net,(uchar) command,arg,
- length ? length :strlen(arg)))
- {
- net->last_errno=CR_SERVER_GONE_ERROR;
- strmov(net->last_error,ER(net->last_errno));
- goto end;
- }
- }
- result=0;
- if (!skipp_check)
- result= ((mysql->packet_length=mc_net_safe_read(mysql)) == packet_error ?
- -1 : 0);
- end:
- return result;
-}
-
-
-MYSQL * STDCALL
-mc_mysql_connect(MYSQL *mysql,const char *host, const char *user,
- const char *passwd, const char *db,
- uint port, const char *unix_socket,uint client_flag)
-{
- char buff[100],*end,*host_info;
- int sock;
- ulong ip_addr;
- struct sockaddr_in sock_addr;
- uint pkt_length;
- NET *net= &mysql->net;
-#ifdef __WIN32__
- HANDLE hPipe=INVALID_HANDLE_VALUE;
-#endif
-#ifdef HAVE_SYS_UN_H
- struct sockaddr_un UNIXaddr;
-#endif
- DBUG_ENTER("mysql_real_connect");
-
- DBUG_PRINT("enter",("host: %s db: %s user: %s",
- host ? host : "(Null)",
- db ? db : "(Null)",
- user ? user : "(Null)"));
-
- bzero((char*) &mysql->options,sizeof(mysql->options));
- net->vio = 0; /* If something goes wrong */
- mysql->charset=default_charset_info; /* Set character set */
- if (!port)
- port = MYSQL_PORT; /* Should always be set by mysqld */
- if (!unix_socket)
- unix_socket=MYSQL_UNIX_ADDR;
-
- mysql->reconnect=1; /* Reconnect as default */
-
- /*
- ** Grab a socket and connect it to the server
- */
-
-#if defined(HAVE_SYS_UN_H)
- if (!host || !strcmp(host,LOCAL_HOST))
- {
- host=LOCAL_HOST;
- host_info=(char*) ER(CR_LOCALHOST_CONNECTION);
- DBUG_PRINT("info",("Using UNIX sock '%s'",unix_socket));
- if ((sock = socket(AF_UNIX,SOCK_STREAM,0)) == SOCKET_ERROR)
- {
- net->last_errno=CR_SOCKET_CREATE_ERROR;
- sprintf(net->last_error,ER(net->last_errno),ERRNO);
- goto error;
- }
- net->vio = vio_new(sock, VIO_TYPE_SOCKET, TRUE);
- bzero((char*) &UNIXaddr,sizeof(UNIXaddr));
- UNIXaddr.sun_family = AF_UNIX;
- strmov(UNIXaddr.sun_path, unix_socket);
- if (mc_sock_connect(sock,(struct sockaddr *) &UNIXaddr, sizeof(UNIXaddr),
- mysql->options.connect_timeout) <0)
- {
- DBUG_PRINT("error",("Got error %d on connect to local server",ERRNO));
- net->last_errno=CR_CONNECTION_ERROR;
- sprintf(net->last_error,ER(net->last_errno),unix_socket,ERRNO);
- goto error;
- }
- }
- else
-#elif defined(__WIN32__)
- {
- if ((unix_socket ||
- !host && is_NT() ||
- host && !strcmp(host,LOCAL_HOST_NAMEDPIPE) ||
- mysql->options.named_pipe || !have_tcpip))
- {
- sock=0;
- if ((hPipe=create_named_pipe(net, mysql->options.connect_timeout,
- (char**) &host, (char**) &unix_socket)) ==
- INVALID_HANDLE_VALUE)
- {
- DBUG_PRINT("error",
- ("host: '%s' socket: '%s' named_pipe: %d have_tcpip: %d",
- host ? host : "<null>",
- unix_socket ? unix_socket : "<null>",
- (int) mysql->options.named_pipe,
- (int) have_tcpip));
- if (mysql->options.named_pipe ||
- (host && !strcmp(host,LOCAL_HOST_NAMEDPIPE)) ||
- (unix_socket && !strcmp(unix_socket,MYSQL_NAMEDPIPE)))
- goto error; /* User only requested named pipes */
- /* Try also with TCP/IP */
- }
- else
- {
- net->vio=vio_new_win32pipe(hPipe);
- sprintf(host_info=buff, ER(CR_NAMEDPIPE_CONNECTION), host,
- unix_socket);
- }
- }
- }
- if (hPipe == INVALID_HANDLE_VALUE)
-#endif
- {
- unix_socket=0; /* This is not used */
- if (!host)
- host=LOCAL_HOST;
- sprintf(host_info=buff,ER(CR_TCP_CONNECTION),host);
- DBUG_PRINT("info",("Server name: '%s'. TCP sock: %d", host,port));
- if ((sock = socket(AF_INET,SOCK_STREAM,0)) == SOCKET_ERROR)
- {
- net->last_errno=CR_IPSOCK_ERROR;
- sprintf(net->last_error,ER(net->last_errno),ERRNO);
- goto error;
- }
- net->vio = vio_new(sock,VIO_TYPE_TCPIP,FALSE);
- bzero((char*) &sock_addr,sizeof(sock_addr));
- sock_addr.sin_family = AF_INET;
-
- /*
- ** The server name may be a host name or IP address
- */
-
- if ((int) (ip_addr = inet_addr(host)) != (int) INADDR_NONE)
- {
- memcpy_fixed(&sock_addr.sin_addr,&ip_addr,sizeof(ip_addr));
- }
- else
-#if defined(HAVE_GETHOSTBYNAME_R) && defined(_REENTRANT) && defined(THREAD)
- {
- int tmp_errno;
- struct hostent tmp_hostent,*hp;
- char buff2[GETHOSTBYNAME_BUFF_SIZE];
- hp = my_gethostbyname_r(host,&tmp_hostent,buff2,sizeof(buff2),
- &tmp_errno);
- if (!hp)
- {
- net->last_errno=CR_UNKNOWN_HOST;
- sprintf(net->last_error, ER(CR_UNKNOWN_HOST), host, tmp_errno);
- goto error;
- }
- memcpy(&sock_addr.sin_addr,hp->h_addr, (size_t) hp->h_length);
- }
-#else
- {
- struct hostent *hp;
- if (!(hp=gethostbyname(host)))
- {
- net->last_errno=CR_UNKNOWN_HOST;
- sprintf(net->last_error, ER(CR_UNKNOWN_HOST), host, errno);
- goto error;
- }
- memcpy(&sock_addr.sin_addr,hp->h_addr, (size_t) hp->h_length);
- }
-#endif
- sock_addr.sin_port = (ushort) htons((ushort) port);
- if (mc_sock_connect(sock,(struct sockaddr *) &sock_addr, sizeof(sock_addr),
- mysql->options.connect_timeout) <0)
- {
- DBUG_PRINT("error",("Got error %d on connect to '%s'",ERRNO,host));
- net->last_errno= CR_CONN_HOST_ERROR;
- sprintf(net->last_error ,ER(CR_CONN_HOST_ERROR), host, ERRNO);
- goto error;
- }
- }
-
- if (!net->vio || my_net_init(net, net->vio))
- {
- vio_delete(net->vio);
- net->last_errno=CR_OUT_OF_MEMORY;
- strmov(net->last_error,ER(net->last_errno));
- goto error;
- }
- vio_keepalive(net->vio,TRUE);
-
- /* Get version info */
- mysql->protocol_version= PROTOCOL_VERSION; /* Assume this */
- if ((pkt_length=mc_net_safe_read(mysql)) == packet_error)
- goto error;
-
- /* Check if version of protocoll matches current one */
-
- mysql->protocol_version= net->read_pos[0];
- DBUG_DUMP("packet",(char*) net->read_pos,10);
- DBUG_PRINT("info",("mysql protocol version %d, server=%d",
- PROTOCOL_VERSION, mysql->protocol_version));
- if (mysql->protocol_version != PROTOCOL_VERSION &&
- mysql->protocol_version != PROTOCOL_VERSION-1)
- {
- net->last_errno= CR_VERSION_ERROR;
- sprintf(net->last_error, ER(CR_VERSION_ERROR), mysql->protocol_version,
- PROTOCOL_VERSION);
- goto error;
- }
- end=strend((char*) net->read_pos+1);
- mysql->thread_id=uint4korr(end+1);
- end+=5;
- strmake(mysql->scramble_buff,end,8);
- if (pkt_length > (uint) (end+9 - (char*) net->read_pos))
- mysql->server_capabilities=uint2korr(end+9);
-
- /* Save connection information */
- if (!user) user="";
- if (!passwd) passwd="";
- if (!my_multi_malloc(MYF(0),
- &mysql->host_info,strlen(host_info)+1,
- &mysql->host,strlen(host)+1,
- &mysql->unix_socket,unix_socket ? strlen(unix_socket)+1
- :1,
- &mysql->server_version,
- (uint) (end - (char*) net->read_pos),
- NullS) ||
- !(mysql->user=my_strdup(user,MYF(0))) ||
- !(mysql->passwd=my_strdup(passwd,MYF(0))))
- {
- strmov(net->last_error, ER(net->last_errno=CR_OUT_OF_MEMORY));
- goto error;
- }
- strmov(mysql->host_info,host_info);
- strmov(mysql->host,host);
- if (unix_socket)
- strmov(mysql->unix_socket,unix_socket);
- else
- mysql->unix_socket=0;
- strmov(mysql->server_version,(char*) net->read_pos+1);
- mysql->port=port;
- mysql->client_flag=client_flag | mysql->options.client_flag;
- DBUG_PRINT("info",("Server version = '%s' capabilites: %ld",
- mysql->server_version,mysql->server_capabilities));
-
- /* Send client information for access check */
- client_flag|=CLIENT_CAPABILITIES;
-
-#ifdef HAVE_OPENSSL
- if (mysql->options.use_ssl)
- client_flag|=CLIENT_SSL;
-#endif /* HAVE_OPENSSL */
-
- if (db)
- client_flag|=CLIENT_CONNECT_WITH_DB;
-#ifdef HAVE_COMPRESS
- if (mysql->server_capabilities & CLIENT_COMPRESS &&
- (mysql->options.compress || client_flag & CLIENT_COMPRESS))
- client_flag|=CLIENT_COMPRESS; /* We will use compression */
- else
-#endif
- client_flag&= ~CLIENT_COMPRESS;
-
-#ifdef HAVE_OPENSSL
- if ((mysql->server_capabilities & CLIENT_SSL) &&
- (mysql->options.use_ssl || (client_flag & CLIENT_SSL)))
- {
- DBUG_PRINT("info", ("Changing IO layer to SSL"));
- client_flag |= CLIENT_SSL;
- }
- else
- {
- if (client_flag & CLIENT_SSL)
- {
- DBUG_PRINT("info", ("Leaving IO layer intact because server doesn't support SSL"));
- }
- client_flag &= ~CLIENT_SSL;
- }
-#endif /* HAVE_OPENSSL */
-
- int2store(buff,client_flag);
- mysql->client_flag=client_flag;
-
-#ifdef HAVE_OPENSSL
- /* Oops.. are we careful enough to not send ANY information */
- /* without encryption? */
- if (client_flag & CLIENT_SSL)
- {
- if (my_net_write(net,buff,(uint) (2)) || net_flush(net))
- goto error;
- /* Do the SSL layering. */
- DBUG_PRINT("info", ("IO layer change in progress..."));
- VioSSLConnectorFd* connector_fd = (VioSSLConnectorFd*)
- (mysql->connector_fd);
- VioSocket* vio_socket = (VioSocket*)(mysql->net.vio);
- VioSSL* vio_ssl = connector_fd->connect(vio_socket);
- mysql->net.vio = (NetVio*)(vio_ssl);
- }
-#endif /* HAVE_OPENSSL */
-
- int3store(buff+2,max_allowed_packet);
- if (user && user[0])
- strmake(buff+5,user,32);
- else
- {
- user = getenv("USER");
- if(!user) user = "mysql";
- strmov((char*) buff+5, user );
- }
-
- DBUG_PRINT("info",("user: %s",buff+5));
- end=scramble(strend(buff+5)+1, mysql->scramble_buff, passwd,
- (my_bool) (mysql->protocol_version == 9));
- if (db)
- {
- end=strmov(end+1,db);
- mysql->db=my_strdup(db,MYF(MY_WME));
- }
- if (my_net_write(net,buff,(uint) (end-buff)) || net_flush(net) ||
- mc_net_safe_read(mysql) == packet_error)
- goto error;
- if (client_flag & CLIENT_COMPRESS) /* We will use compression */
- net->compress=1;
- DBUG_PRINT("exit",("Mysql handler: %lx",mysql));
- DBUG_RETURN(mysql);
-
-error:
- DBUG_PRINT("error",("message: %u (%s)",net->last_errno,net->last_error));
- {
- /* Free alloced memory */
- my_bool free_me=mysql->free_me;
- mc_end_server(mysql);
- mysql->free_me=0;
- mc_mysql_close(mysql);
- mysql->free_me=free_me;
- }
- DBUG_RETURN(0);
-}
-
-/*************************************************************************
-** Send a QUIT to the server and close the connection
-** If handle is alloced by mysql connect free it.
-*************************************************************************/
-
-void STDCALL
-mc_mysql_close(MYSQL *mysql)
-{
- DBUG_ENTER("mysql_close");
- if (mysql) /* Some simple safety */
- {
- if (mysql->net.vio != 0)
- {
- mc_free_old_query(mysql);
- mysql->status=MYSQL_STATUS_READY; /* Force command */
- mc_simple_command(mysql,COM_QUIT,NullS,0,1);
- mc_end_server(mysql);
- }
- my_free((gptr) mysql->host_info,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->user,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->passwd,MYF(MY_ALLOW_ZERO_PTR));
- my_free(mysql->db,MYF(MY_ALLOW_ZERO_PTR));
- /* Clear pointers for better safety */
- mysql->host_info=mysql->user=mysql->passwd=mysql->db=0;
- bzero((char*) &mysql->options,sizeof(mysql->options));
- mysql->net.vio = 0;
-#ifdef HAVE_OPENSSL
- ((VioConnectorFd*)(mysql->connector_fd))->delete();
- mysql->connector_fd = 0;
-#endif /* HAVE_OPENSSL */
- if (mysql->free_me)
- my_free((gptr) mysql,MYF(0));
- }
- DBUG_VOID_RETURN;
-}
diff --git a/sql/Attic/mini_client_errors.c b/sql/Attic/mini_client_errors.c
deleted file mode 100644
index 96f1f415544..00000000000
--- a/sql/Attic/mini_client_errors.c
+++ /dev/null
@@ -1,64 +0,0 @@
-/* Copyright Abandoned 1997 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* Error messages for MySQL clients */
-/* error messages for the demon is in share/language/errmsg.sys */
-
-#include <global.h>
-#include <my_sys.h>
-#include "errmsg.h"
-
-#ifdef GERMAN
-const char *client_errors[]=
-{
- "Unbekannter MySQL Fehler",
- "Kann UNIX-Socket nicht anlegen (%d)",
- "Keine Verbindung zu lokalem MySQL Server, socket: '%-.64s' (%d)",
- "Keine Verbindung zu MySQL Server auf %-.64s (%d)",
- "Kann TCP/IP-Socket nicht anlegen (%d)",
- "Unbekannter MySQL Server Host (%-.64s) (%d)",
- "MySQL Server nicht vorhanden",
- "Protokolle ungleich. Server Version = % d Client Version = %d",
- "MySQL client got out of memory",
- "Wrong host info",
- "Localhost via UNIX socket",
- "%s via TCP/IP",
- "Error in server handshake",
- "Lost connection to MySQL server during query",
- "Commands out of sync; You can't run this command now",
- "Verbindung ueber Named Pipe; Host: %-.64s",
- "Kann nicht auf Named Pipe warten. Host: %-.64s pipe: %-.32s (%lu)",
- "Kann Named Pipe nicht oeffnen. Host: %-.64s pipe: %-.32s (%lu)",
- "Kann den Status der Named Pipe nicht setzen. Host: %-.64s pipe: %-.32s (%lu)"
-};
-
-#else /* ENGLISH */
-const char *client_errors[]=
-{
- "Unknown MySQL error",
- "Can't create UNIX socket (%d)",
- "Can't connect to local MySQL server through socket '%-.64s' (%d)",
- "Can't connect to MySQL server on '%-.64s' (%d)",
- "Can't create TCP/IP socket (%d)",
- "Unknown MySQL Server Host '%-.64s' (%d)",
- "MySQL server has gone away",
- "Protocol mismatch. Server Version = %d Client Version = %d",
- "MySQL client run out of memory",
- "Wrong host info",
- "Localhost via UNIX socket",
- "%s via TCP/IP",
- "Error in server handshake",
- "Lost connection to MySQL server during query",
- "Commands out of sync; You can't run this command now",
- "%s via named pipe",
- "Can't wait for named pipe to host: %-.64s pipe: %-.32s (%lu)",
- "Can't open named pipe to host: %-.64s pipe: %-.32s (%lu)",
- "Can't set state of named pipe to host: %-.64s pipe: %-.32s (%lu)",
-};
-#endif
-
-
-void init_client_errs(void)
-{
- errmsg[CLIENT_ERRMAP] = &client_errors[0];
-}
diff --git a/sql/Attic/mybinlogdump.cc b/sql/Attic/mybinlogdump.cc
deleted file mode 100644
index b94943c9847..00000000000
--- a/sql/Attic/mybinlogdump.cc
+++ /dev/null
@@ -1,138 +0,0 @@
-
-#undef MYSQL_SERVER
-#include "log_event.h"
-#include <getopt.h>
-#include <config.h>
-
-static const char* default_dbug_option = "d:t:o,/tmp/mybinlogdump.trace";
-
-static struct option long_options[] =
-{
- {"short-form", no_argument, 0, 's'},
- {"offset", required_argument,0, 'o'},
- {"help", no_argument, 0, 'h'},
-#ifndef DBUG_OFF
- {"debug", required_argument, 0, '#'}
-#endif
-};
-
-static bool short_form = 0;
-static int offset = 0;
-
-static int parse_args(int argc, char** argv);
-static void dump_log_entries();
-static void die(char* fmt, ...);
-
-static void die(char* fmt, ...)
-{
- va_list args;
- va_start(args, fmt);
- fprintf(stderr, "ERROR: ");
- vfprintf(stderr, fmt, args);
- fprintf(stderr, "\n");
- va_end(args);
- exit(1);
-}
-
-static void usage()
-{
- fprintf(stderr, "Usage: mybinlogdump [options] log-files\n");
- fprintf(stderr, "Options:\n\
- -s,--short-form - just show the queries, no extra info\n\
- -o,--offset=N - skip the first N entries\n\
- -h,--help - this message\n");
-}
-
-static int parse_args(int *argc, char*** argv)
-{
- int c, opt_index = 0;
-
- while((c = getopt_long(*argc, *argv, "so:#:h", long_options,
- &opt_index)) != EOF)
- {
- switch(c)
- {
-#ifndef DBUG_OFF
- case '#':
- DBUG_PUSH(optarg ? optarg : default_dbug_option);
- break;
-#endif
- case 's':
- short_form = 1;
- break;
-
- case 'o':
- offset = atoi(optarg);
- break;
-
- case 'h':
- default:
- usage();
- exit(0);
-
- }
- }
-
- (*argc)-=optind;
- (*argv)+=optind;
-
-
- return 0;
-}
-
-
-static void dump_log_entries(const char* logname)
-{
- FILE* file;
- int rec_count = 0;
-
- if(logname && logname[0] != '-')
- file = my_fopen(logname, O_RDONLY, MYF(MY_WME));
- else
- file = stdin;
-
- if(!file)
- die("Could not open log file %s", logname);
- while(1)
- {
- Log_event* ev = Log_event::read_log_event(file);
- if(!ev)
- if(!feof(file))
- die("Could not read entry at offset %ld : Error in log format or \
-read error",
- my_ftell(file, MYF(MY_WME)));
- else
- break;
-
- if(rec_count >= offset)
- ev->print(stdout, short_form);
- rec_count++;
- delete ev;
- }
-
- my_fclose(file, MYF(MY_WME));
-}
-
-int main(int argc, char** argv)
-{
- MY_INIT(argv[0]);
- parse_args(&argc, (char***)&argv);
-
- if(!argc)
- {
- usage();
- return -1;
- }
-
- while(--argc >= 0)
- {
- dump_log_entries(*(argv++));
- }
-
- return 0;
-}
-
-
-
-
-
diff --git a/sql/Attic/net_serv.c b/sql/Attic/net_serv.c
deleted file mode 100644
index 8f5ba20664a..00000000000
--- a/sql/Attic/net_serv.c
+++ /dev/null
@@ -1,616 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* Write and read of logical packets to/from socket
-** Writes are cached into net_buffer_length big packets.
-** Read packets are reallocated dynamicly when reading big packets.
-** Each logical packet has the following pre-info:
-** 3 byte length & 1 byte package-number.
-*/
-
-#ifdef _WIN32
-#include <winsock.h>
-#endif
-#include <global.h>
-#include <violite.h>
-#include <my_sys.h>
-#include <m_string.h>
-#include "mysql.h"
-#include <signal.h>
-#include <errno.h>
-#include <sys/types.h>
-#include <violite.h>
-
-#if !defined(__WIN32__) && !defined(MSDOS)
-#include <sys/socket.h>
-#endif
-#if !defined(MSDOS) && !defined(__WIN32__) && !defined(HAVE_BROKEN_NETINET_INCLUDES) && !defined(__BEOS__)
-#include <netinet/in_systm.h>
-#include <netinet/in.h>
-#include <netinet/ip.h>
-#if !defined(alpha_linux_port)
-#include <netinet/tcp.h>
-#endif
-#endif
-#include "mysqld_error.h"
-#ifdef MYSQL_SERVER
-#include "my_pthread.h"
-#include "thr_alarm.h"
-void sql_print_error(const char *format,...);
-#define RETRY_COUNT mysqld_net_retry_count
-extern ulong mysqld_net_retry_count;
-#else
-typedef my_bool thr_alarm_t;
-#define thr_alarm_init(A) (*A)=0
-#define thr_alarm_in_use(A) (A)
-#define thr_end_alarm(A)
-#define thr_alarm(A,B) local_thr_alarm((A),(B))
-static inline int local_thr_alarm(my_bool *A,int B __attribute__((unused)))
-{
- *A=1;
- return 0;
-}
-#define thr_got_alarm(A) 0
-#define RETRY_COUNT 1
-#endif
-
-#ifdef MYSQL_SERVER
-extern ulong bytes_sent, bytes_received;
-extern pthread_mutex_t LOCK_bytes_sent , LOCK_bytes_received;
-#else
-#undef thread_safe_add
-#define thread_safe_add(A,B,C)
-#endif
-
-/*
-** Give error if a too big packet is found
-** The server can change this with the -O switch, but because the client
-** can't normally do this the client should have a bigger max-buffer.
-*/
-
-#ifdef MYSQL_SERVER
-ulong max_allowed_packet=65536;
-extern uint test_flags;
-#else
-ulong max_allowed_packet=16*1024*1024L;
-#endif
-ulong net_buffer_length=8192; /* Default length. Enlarged if necessary */
-
-#define TEST_BLOCKING 8
-static int net_write_buff(NET *net,const char *packet,uint len);
-
-
- /* Init with packet info */
-
-int my_net_init(NET *net, Vio* vio)
-{
- if (!(net->buff=(uchar*) my_malloc(net_buffer_length,MYF(MY_WME))))
- return 1;
- if (net_buffer_length > max_allowed_packet)
- max_allowed_packet=net_buffer_length;
- net->buff_end=net->buff+(net->max_packet=net_buffer_length);
- net->vio = vio;
- net->error=net->return_errno=0;
- net->timeout=NET_READ_TIMEOUT; /* Timeout for read */
- net->pkt_nr=0;
- net->write_pos=net->read_pos = net->buff;
- net->last_error[0]=0;
- net->compress=0; net->reading_or_writing=0;
- net->where_b = net->remain_in_buf=0;
- net->last_errno=0;
-
- if (vio != 0) /* If real connection */
- {
- net->fd = vio_fd(vio); /* For perl DBI/DBD */
-#if defined(MYSQL_SERVER) && !defined(___WIN32__) && !defined(__EMX__)
- if (!(test_flags & TEST_BLOCKING))
- vio_blocking(vio, FALSE);
-#endif
- vio_fastsend(vio,TRUE);
- }
- return 0;
-}
-
-void net_end(NET *net)
-{
- my_free((gptr) net->buff,MYF(MY_ALLOW_ZERO_PTR));
- net->buff=0;
-}
-
-/* Realloc the packet buffer */
-
-static my_bool net_realloc(NET *net, ulong length)
-{
- uchar *buff;
- ulong pkt_length;
- if (length >= max_allowed_packet)
- {
- DBUG_PRINT("error",("Packet too large (%ld)", length));
-#ifdef MYSQL_SERVER
- sql_print_error("Packet too large (%ld)\n", length);
-#else
- fprintf(stderr,"Packet too large (%ld)\n", length);
-#endif
- net->error=1;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_PACKET_TOO_LARGE;
-#endif
- return 1;
- }
- pkt_length = (length+IO_SIZE-1) & ~(IO_SIZE-1);
- if (!(buff=(uchar*) my_realloc((char*) net->buff, pkt_length, MYF(MY_WME))))
- {
- net->error=1;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_OUT_OF_RESOURCES;
-#endif
- return 1;
- }
- net->buff=net->write_pos=buff;
- net->buff_end=buff+(net->max_packet=pkt_length);
- return 0;
-}
-
- /* Remove unwanted characters from connection */
-
-void net_clear(NET *net)
-{
-#ifndef EXTRA_DEBUG
- int count;
- bool is_blocking=vio_is_blocking(net->vio);
- if (is_blocking)
- vio_blocking(net->vio, FALSE);
- if (!vio_is_blocking(net->vio)) /* Safety if SSL */
- {
- while ( (count = vio_read(net->vio, (char*) (net->buff),
- net->max_packet)) > 0)
- DBUG_PRINT("info",("skipped %d bytes from file: %s",
- count,vio_description(net->vio)));
- if (is_blocking)
- vio_blocking(net->vio, TRUE);
- }
-#endif /* EXTRA_DEBUG */
- net->pkt_nr=0; /* Ready for new command */
- net->write_pos=net->buff;
-}
-
- /* Flush write_buffer if not empty. */
-
-int net_flush(NET *net)
-{
- int error=0;
- DBUG_ENTER("net_flush");
- if (net->buff != net->write_pos)
- {
- error=net_real_write(net,(char*) net->buff,
- (uint) (net->write_pos - net->buff));
- net->write_pos=net->buff;
- }
- DBUG_RETURN(error);
-}
-
-
-/*****************************************************************************
-** Write something to server/client buffer
-*****************************************************************************/
-
-
-/*
-** Write a logical packet with packet header
-** Format: Packet length (3 bytes), packet number(1 byte)
-** When compression is used a 3 byte compression length is added
-** NOTE: If compression is used the original package is destroyed!
-*/
-
-int
-my_net_write(NET *net,const char *packet,ulong len)
-{
- uchar buff[NET_HEADER_SIZE];
- int3store(buff,len);
- buff[3]= (net->compress) ? 0 : (uchar) (net->pkt_nr++);
- if (net_write_buff(net,(char*) buff,NET_HEADER_SIZE))
- return 1;
- return net_write_buff(net,packet,len);
-}
-
-int
-net_write_command(NET *net,uchar command,const char *packet,ulong len)
-{
- uchar buff[NET_HEADER_SIZE+1];
- uint length=len+1; /* 1 extra byte for command */
-
- int3store(buff,length);
- buff[3]= (net->compress) ? 0 : (uchar) (net->pkt_nr++);
- buff[4]=command;
- if (net_write_buff(net,(char*) buff,5))
- return 1;
- return test(net_write_buff(net,packet,len) || net_flush(net));
-}
-
-
-static int
-net_write_buff(NET *net,const char *packet,uint len)
-{
- uint left_length=(uint) (net->buff_end - net->write_pos);
-
- while (len > left_length)
- {
- memcpy((char*) net->write_pos,packet,left_length);
- if (net_real_write(net,(char*) net->buff,net->max_packet))
- return 1;
- net->write_pos=net->buff;
- packet+=left_length;
- len-=left_length;
- left_length=net->max_packet;
- }
- memcpy((char*) net->write_pos,packet,len);
- net->write_pos+=len;
- return 0;
-}
-
-/* Read and write using timeouts */
-
-int
-net_real_write(NET *net,const char *packet,ulong len)
-{
- int length;
- char *pos,*end;
- thr_alarm_t alarmed;
- uint retry_count=0;
- my_bool net_blocking = vio_is_blocking(net->vio);
- DBUG_ENTER("net_real_write");
-
- net->reading_or_writing=2;
-#ifdef HAVE_COMPRESS
- if (net->compress)
- {
- ulong complen;
- uchar *b;
- uint header_length=NET_HEADER_SIZE+COMP_HEADER_SIZE;
- if (!(b=(uchar*) my_malloc(len + NET_HEADER_SIZE + COMP_HEADER_SIZE,
- MYF(MY_WME))))
- {
-#ifdef MYSQL_SERVER
- net->last_errno=ER_OUT_OF_RESOURCES;
- net->error=1;
-#endif
- net->reading_or_writing=0;
- DBUG_RETURN(1);
- }
- memcpy(b+header_length,packet,len);
-
- if (my_compress((byte*) b+header_length,&len,&complen))
- {
- DBUG_PRINT("warning",
- ("Compression error; Continuing without compression"));
- complen=0;
- }
- int3store(&b[NET_HEADER_SIZE],complen);
- int3store(b,len);
- b[3]=(uchar) (net->pkt_nr++);
- len+= header_length;
- packet= (char*) b;
- }
-#endif /* HAVE_COMPRESS */
-
- /* DBUG_DUMP("net",packet,len); */
-#ifdef MYSQL_SERVER
- thr_alarm_init(&alarmed);
- if (net_blocking)
- thr_alarm(&alarmed,NET_WRITE_TIMEOUT);
-#else
- alarmed=0;
-#endif /* MYSQL_SERVER */
-
- pos=(char*) packet; end=pos+len;
- while (pos != end)
- {
- if ((int) (length=vio_write(net->vio,pos,(size_t) (end-pos))) <= 0)
- {
- my_bool interrupted = vio_should_retry(net->vio);
-#if (!defined(__WIN32__) && !defined(__EMX__))
- if ((interrupted || length==0) && !thr_alarm_in_use(alarmed))
- {
- if (!thr_alarm(&alarmed,NET_WRITE_TIMEOUT))
- { /* Always true for client */
- if (!vio_is_blocking(net->vio))
- {
- while (vio_blocking(net->vio, TRUE) < 0)
- {
- if (vio_should_retry(net->vio) && retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr,
- "%s: my_net_write: fcntl returned error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- net->error=1; /* Close socket */
- goto end;
- }
- }
- retry_count=0;
- continue;
- }
- }
- else
-#endif /* (!defined(__WIN32__) && !defined(__EMX__)) */
- if (thr_alarm_in_use(alarmed) && !thr_got_alarm(alarmed) &&
- interrupted)
- {
- if (retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr, "%s: write looped, aborting thread\n",
- my_progname);
-#endif /* EXTRA_DEBUG */
- }
-#if defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER)
- if (vio_errno(net->vio) == EINTR)
- {
- DBUG_PRINT("warning",("Interrupted write. Retrying..."));
- continue;
- }
-#endif /* defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER) */
- net->error=1; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno= (interrupted ? ER_NET_WRITE_INTERRUPTED :
- ER_NET_ERROR_ON_WRITE);
-#endif /* MYSQL_SERVER */
- break;
- }
- pos+=length;
- thread_safe_add(bytes_sent,length,&LOCK_bytes_sent);
- }
-#ifndef __WIN32__
- end:
-#endif
-#ifdef HAVE_COMPRESS
- if (net->compress)
- my_free((char*) packet,MYF(0));
-#endif
- if (thr_alarm_in_use(alarmed))
- {
- thr_end_alarm(&alarmed);
- vio_blocking(net->vio, net_blocking);
- }
- net->reading_or_writing=0;
- DBUG_RETURN(((int) (pos != end)));
-}
-
-
-/*****************************************************************************
-** Read something from server/clinet
-*****************************************************************************/
-
-
-static uint
-my_real_read(NET *net, ulong *complen)
-{
- uchar *pos;
- long length;
- uint i,retry_count=0;
- ulong len=packet_error;
- thr_alarm_t alarmed;
- my_bool net_blocking=vio_is_blocking(net->vio);
- ulong remain= (net->compress ? NET_HEADER_SIZE+COMP_HEADER_SIZE :
- NET_HEADER_SIZE);
- *complen = 0;
-
- net->reading_or_writing=1;
- thr_alarm_init(&alarmed);
-#ifdef MYSQL_SERVER
- if (net_blocking)
- thr_alarm(&alarmed,net->timeout);
-#endif /* MYSQL_SERVER */
-
- pos = net->buff + net->where_b; /* net->packet -4 */
- for (i=0 ; i < 2 ; i++)
- {
- while (remain > 0)
- {
- /* First read is done with non blocking mode */
- if ((int) (length=vio_read(net->vio,(char*) pos,remain)) <= 0L)
- {
- my_bool interrupted = vio_should_retry(net->vio);
-
- DBUG_PRINT("info",("vio_read returned %d, errno: %d",
- length, vio_errno(net->vio)));
-#if (!defined(__WIN32__) && !defined(__EMX__)) || !defined(MYSQL_SERVER)
- /*
- We got an error that there was no data on the socket. We now set up
- an alarm to not 'read forever', change the socket to non blocking
- mode and try again
- */
- if ((interrupted || length == 0) && !thr_alarm_in_use(alarmed))
- {
- if (!thr_alarm(&alarmed,net->timeout)) /* Don't wait too long */
- {
- if (!vio_is_blocking(net->vio))
- {
- while (vio_blocking(net->vio,TRUE) < 0)
- {
- if (vio_should_retry(net->vio) &&
- retry_count++ < RETRY_COUNT)
- continue;
- DBUG_PRINT("error",
- ("fcntl returned error %d, aborting thread",
- vio_errno(net->vio)));
-#ifdef EXTRA_DEBUG
- fprintf(stderr,
- "%s: read: fcntl returned error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- len= packet_error;
- net->error=1; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_FCNTL_ERROR;
-#endif
- goto end;
- }
- }
- retry_count=0;
- continue;
- }
- }
-#endif /* (!defined(__WIN32__) && !defined(__EMX__)) || !defined(MYSQL_SERVER) */
- if (thr_alarm_in_use(alarmed) && !thr_got_alarm(alarmed) &&
- interrupted)
- { /* Probably in MIT threads */
- if (retry_count++ < RETRY_COUNT)
- continue;
-#ifdef EXTRA_DEBUG
- fprintf(stderr, "%s: read looped with error %d, aborting thread\n",
- my_progname,vio_errno(net->vio));
-#endif /* EXTRA_DEBUG */
- }
-#if defined(THREAD_SAFE_CLIENT) && !defined(MYSQL_SERVER)
- if (vio_should_retry(net->vio))
- {
- DBUG_PRINT("warning",("Interrupted read. Retrying..."));
- continue;
- }
-#endif
- DBUG_PRINT("error",("Couldn't read packet: remain: %d errno: %d length: %d alarmed: %d", remain,vio_errno(net->vio),length,alarmed));
- len= packet_error;
- net->error=1; /* Close socket */
-#ifdef MYSQL_SERVER
- net->last_errno= (interrupted ? ER_NET_READ_INTERRUPTED :
- ER_NET_READ_ERROR);
-#endif
- goto end;
- }
- remain -= (ulong) length;
- pos+= (ulong) length;
- thread_safe_add(bytes_received,(ulong) length,&LOCK_bytes_received);
- }
- if (i == 0)
- { /* First parts is packet length */
- ulong helping;
- if (net->buff[net->where_b + 3] != (uchar) net->pkt_nr)
- {
- if (net->buff[net->where_b] != (uchar) 255)
- {
- DBUG_PRINT("error",
- ("Packets out of order (Found: %d, expected %d)",
- (int) net->buff[net->where_b + 3],
- (uint) (uchar) net->pkt_nr));
-#ifdef EXTRA_DEBUG
- fprintf(stderr,"Packets out of order (Found: %d, expected %d)\n",
- (int) net->buff[net->where_b + 3],
- (uint) (uchar) net->pkt_nr);
-#endif
- }
- len= packet_error;
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_PACKETS_OUT_OF_ORDER;
-#endif
- goto end;
- }
- net->pkt_nr++;
-#ifdef HAVE_COMPRESS
- if (net->compress)
- {
- /* complen is > 0 if package is really compressed */
- *complen=uint3korr(&(net->buff[net->where_b + NET_HEADER_SIZE]));
- }
-#endif
-
- len=uint3korr(net->buff+net->where_b);
- helping = max(len,*complen) + net->where_b;
- /* The necessary size of net->buff */
- if (helping >= net->max_packet)
- {
- /* We must allocate one extra byte for the end null */
- if (net_realloc(net,helping+1))
- {
- len= packet_error; /* Return error */
- goto end;
- }
- }
- pos=net->buff + net->where_b;
- remain = len;
- }
- }
-
-end:
- if (thr_alarm_in_use(alarmed))
- {
- thr_end_alarm(&alarmed);
- vio_blocking(net->vio, net_blocking);
- }
- net->reading_or_writing=0;
- return(len);
-}
-
-
-uint
-my_net_read(NET *net)
-{
- ulong len,complen;
-
-#ifdef HAVE_COMPRESS
- if (!net->compress)
- {
-#endif
- len = my_real_read (net,&complen);
- net->read_pos = net->buff + net->where_b;
- if (len != packet_error)
- net->read_pos[len]=0; /* Safeguard for mysql_use_result */
- return len;
-#ifdef HAVE_COMPRESS
- }
- if (net->remain_in_buf)
- net->buff[net->buf_length - net->remain_in_buf]=net->save_char;
- for (;;)
- {
- if (net->remain_in_buf)
- {
- uchar *pos = net->buff + net->buf_length - net->remain_in_buf;
- if (net->remain_in_buf >= 4)
- {
- net->length = uint3korr(pos);
- if (net->length <= net->remain_in_buf - 4)
- {
- /* We have a full packet */
- len=net->length;
- net->remain_in_buf -= net->length + 4;
- net->read_pos=pos + 4;
- break; /* We have a full packet */
- }
- }
- /* Move data down to read next data packet after current one */
- if (net->buf_length != net->remain_in_buf)
- {
- memmove(net->buff,pos,net->remain_in_buf);
- net->buf_length=net->remain_in_buf;
- }
- net->where_b=net->buf_length;
- }
- else
- {
- net->where_b=0;
- net->buf_length=0;
- }
-
- if ((len = my_real_read(net,&complen)) == packet_error)
- break;
- if (my_uncompress((byte*) net->buff + net->where_b, &len, &complen))
- {
- len= packet_error;
- net->error=1; /* caller will close socket */
-#ifdef MYSQL_SERVER
- net->last_errno=ER_NET_UNCOMPRESS_ERROR;
-#endif
- break;
- }
- net->buf_length+=len;
- net->remain_in_buf+=len;
- }
- if (len != packet_error)
- {
- net->save_char= net->read_pos[len]; /* Must be saved */
- net->read_pos[len]=0; /* Safeguard for mysql_use_result */
- }
- return len;
-#endif
-}
diff --git a/sql/ha_berkeley.h b/sql/ha_berkeley.h
index 94d12dd2a56..9724d128b1f 100644
--- a/sql/ha_berkeley.h
+++ b/sql/ha_berkeley.h
@@ -165,6 +165,7 @@ class ha_berkeley: public handler
};
extern bool berkeley_skip, berkeley_shared_data;
+extern SHOW_COMP_OPTION have_berkeley_db;
extern u_int32_t berkeley_init_flags,berkeley_env_flags, berkeley_lock_type,
berkeley_lock_types[];
extern ulong berkeley_cache_size, berkeley_max_lock, berkeley_log_buffer_size;
diff --git a/sql/ha_gemini.cc b/sql/ha_gemini.cc
index 863a0d6931c..73241c60be7 100644
--- a/sql/ha_gemini.cc
+++ b/sql/ha_gemini.cc
@@ -19,12 +19,10 @@
#pragma implementation // gcc: Class implementation
#endif
-#include <string.h>
-
#include "mysql_priv.h"
-#include "my_pthread.h"
-
#ifdef HAVE_GEMINI_DB
+
+#include "my_pthread.h"
#include "dbconfig.h"
#include "dsmpub.h"
#include "recpub.h"
diff --git a/sql/ha_innobase.cc b/sql/ha_innobase.cc
index 45dcb4e80df..0debae9a797 100644
--- a/sql/ha_innobase.cc
+++ b/sql/ha_innobase.cc
@@ -2462,10 +2462,10 @@ ha_innobase::records_in_range(
index = dict_table_get_index_noninline(prebuilt->table, key->name);
range_start = dtuple_create_for_mysql(&heap1, key->key_parts);
- dict_index_copy_types(range_start, index, index->n_fields);
+ dict_index_copy_types(range_start, index, key->key_parts);
range_end = dtuple_create_for_mysql(&heap2, key->key_parts);
- dict_index_copy_types(range_end, index, index->n_fields);
+ dict_index_copy_types(range_end, index, key->key_parts);
row_sel_convert_mysql_key_to_innobase(
range_start, (byte*) key_val_buff, index,
diff --git a/sql/handler.cc b/sql/handler.cc
index 600683d9c18..f057b75d498 100644
--- a/sql/handler.cc
+++ b/sql/handler.cc
@@ -151,6 +151,8 @@ int ha_init()
return error;
if (!berkeley_skip) // If we couldn't use handler
opt_using_transactions=1;
+ else
+ have_berkeley_db=SHOW_OPTION_DISABLED;
}
#endif
#ifdef HAVE_INNOBASE_DB
@@ -159,10 +161,9 @@ int ha_init()
if (innobase_init())
return -1;
if (!innobase_skip) // If we couldn't use handler
- {
opt_using_transactions=1;
+ else
have_innobase=SHOW_OPTION_DISABLED;
- }
}
#endif
#ifdef HAVE_GEMINI_DB
@@ -171,10 +172,9 @@ int ha_init()
if (gemini_init())
return -1;
if (!gemini_skip) // If we couldn't use handler
- {
opt_using_transactions=1;
+ else
have_gemini=SHOW_OPTION_DISABLED;
- }
}
#endif
return 0;
diff --git a/sql/mysqld.cc b/sql/mysqld.cc
index 9b33c7efa51..6311e86a154 100644
--- a/sql/mysqld.cc
+++ b/sql/mysqld.cc
@@ -2112,7 +2112,7 @@ static void create_new_thread(THD *thd)
(void) pthread_mutex_unlock(&LOCK_thread_count);
}
}
- DBUG_PRINT("info",(("Thread %d created"), thd->thread_id));
+ DBUG_PRINT("info",("Thread created"));
DBUG_VOID_RETURN;
}
diff --git a/strings/Attic/bootstrap-ctype.c b/strings/Attic/bootstrap-ctype.c
deleted file mode 100644
index dea3fcbb03c..00000000000
--- a/strings/Attic/bootstrap-ctype.c
+++ /dev/null
@@ -1,91 +0,0 @@
-/* Bootstrap configuration file (from the latin1 character set) */
-#include <global.h>
-#include <m_ctype.h>
-
-/*
- * This comment is parsed by configure to create ctype.c,
- * so don't change it unless you know what you are doing.
- *
- * .configure. number_BOOTSTRAP=0
- */
-
-/* ctype array must have 257 elements */
-uchar ctype_BOOTSTRAP[257] = {
- 0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 32,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 16, 1, 1, 1, 1, 1, 1, 1, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16, 2, 2, 2, 2, 2, 2, 2, 2
-};
-
-/* to_lower array must have 256 elements */
-uchar to_lower_BOOTSTRAP[256] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
- 112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
- 112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
- 128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
- 144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
- 160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
- 176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
- 224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
- 240,241,242,243,244,245,246,215,248,249,250,251,252,253,254,223,
- 224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
- 240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255
-};
-
-/* to_upper array must have 256 elements */
-uchar to_upper_BOOTSTRAP[256] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
- 128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
- 144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
- 160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
- 176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
- 192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
- 208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
- 192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
- 208,209,210,211,212,213,214,247,216,217,218,219,220,221,222,255
-};
-
-/* sort_order array must have 256 elements */
-uchar sort_order_BOOTSTRAP[256] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
- 128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
- 144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
- 160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
- 176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
- 65, 65, 65, 65, 92, 91, 92, 67, 69, 69, 69, 69, 73, 73, 73, 73,
- 68, 78, 79, 79, 79, 79, 93,215,216, 85, 85, 85, 89, 89,222,223,
- 65, 65, 65, 65, 92, 91, 92, 67, 69, 69, 69, 69, 73, 73, 73, 73,
- 68, 78, 79, 79, 79, 79, 93,247,216, 85, 85, 85, 89, 89,222,255
-};
diff --git a/strings/Attic/ct_init.c b/strings/Attic/ct_init.c
deleted file mode 100644
index b0b1a8e126b..00000000000
--- a/strings/Attic/ct_init.c
+++ /dev/null
@@ -1,6 +0,0 @@
-/* Generate definitions of ctype arrays
-*/
-
-#include <global.h>
-#define CTYPE_LIBRARY /* initialize ctype arrays */
-#include "m_ctype.h"
diff --git a/strings/Attic/ctype-cp1251.c b/strings/Attic/ctype-cp1251.c
deleted file mode 100644
index e717fd49c9e..00000000000
--- a/strings/Attic/ctype-cp1251.c
+++ /dev/null
@@ -1,88 +0,0 @@
-/* ctype-cp1251.c */
-
-/*
- * File generated by cset
- * (C) Abandoned 1997 Zarko Mocnik <zarko.mocnik@dem.si>
- *
- * This file is obsolete; Please use ctype-win1251 instead!
- */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_cp1251[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 72, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-};
-
-uchar NEAR to_lower_cp1251[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,184,169,170,171,172,173,174,175,
-176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,
-};
-
-uchar NEAR to_upper_cp1251[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
-176,177,178,179,180,181,182,183,168,185,186,187,188,189,190,191,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-};
-
-uchar NEAR sort_order_cp1251[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,124,125,126,127,128,
-129, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,130,131,132,133,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255, 97,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255, 97,255,255,255,255,255,255,255,
- 91, 92, 93, 94, 95, 96, 98, 99,100,101,102,103,104,105,106,107,
-108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,
- 91, 92, 93, 94, 95, 96, 98, 99,100,101,102,103,104,105,106,107,
-108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,
-};
diff --git a/strings/Attic/ctype-cp1257.c b/strings/Attic/ctype-cp1257.c
deleted file mode 100644
index c60f71f635b..00000000000
--- a/strings/Attic/ctype-cp1257.c
+++ /dev/null
@@ -1,88 +0,0 @@
-/* cp1257 (Lithuanian)
- * Created by Miroslav Stanish , Vilnius, 1999
- * This file is public domain and comes with no warranty of any kind
- * Pleace send comments and bug reports to: <miroslav@mail.lt>
- *
- * File generated by cset
- * (C) Abandoned 1997 Zarko Mocnik <zarko.mocnik@dem.si>
- */
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_cp1257[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0,
- 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0,
- 2, 2, 0, 0, 0, 0, 2, 0, 2, 0, 0, 2, 0, 0, 0, 0,
- 2, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 2, 0, 0, 2, 0,
-};
-
-uchar NEAR to_lower_cp1257[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
-176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
-224,225,194,195,196,197,230,199,232,201,202,235,204,205,206,207,
-240,209,210,211,212,213,214,215,248,217,218,251,220,221,254,223,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,
-};
-
-uchar NEAR to_upper_cp1257[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
-176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-192,193,226,227,228,229,198,231,200,233,234,203,236,237,238,239,
-208,241,242,243,244,245,246,247,216,249,250,219,252,253,222,255,
-};
-
-uchar NEAR sort_order_cp1257[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 67, 68, 70, 71, 74, 75, 76, 77, 80, 81, 82, 83, 84, 85,
- 86, 87, 88, 89, 91, 92, 95, 96, 97, 78,255, 98, 99,100,101,102,
-103, 65, 67, 68, 70, 71, 74, 75, 76, 77, 80, 81, 82, 83, 84, 85,
- 86, 87, 88, 89, 91, 92, 95, 96, 97, 78,255,104,105,106,107,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
- 66, 79,255,255,255,255, 72,255, 69,255,255, 73,255,255,255,255,
- 90,255,255,255,255,255,255,255, 94,255,255, 93,255,255,255,255,
-255, 79,255,255,255,255, 72,255, 69,255,255, 73,255,255,255,255,
- 90,255,255,255,255,255,255,255, 94,255,255, 93,255,255,255,255,
-};
-
diff --git a/strings/Attic/ctype-croat.c b/strings/Attic/ctype-croat.c
deleted file mode 100644
index 144ef337705..00000000000
--- a/strings/Attic/ctype-croat.c
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- This file is free for using
- Author: Hrvoje Devcic, hdevcic@posluh.hr;
- Sintaxx Error Software
- POSLuH d.o.o., Zagreb, Croatia - http://www.posluh.hr
-*/
-
-/* This implements the hr (Croatian) character-set */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_croat[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,
-0,0,0,0,0,0,0,0,0,2,0,0,0,2,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_croat[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) 154,(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) 158,(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) 230,(uchar) '\347',
-(uchar) 232,(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) 240,(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\327',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_croat[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) 138,(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) 142,(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) 198,(uchar) '\307',
-(uchar) 200,(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) 208,(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-};
-
-#ifndef __WIN32__
-uchar NEAR sort_order_croat[]={
-#else
-uchar sort_order_croat[]={
-#endif
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 65, 66, 67, 70, 72, 73, 74,
- 75, 76, 77, 78, 79, 80, 81, 82,
- 83, 84, 85, 86, 88, 89, 90, 91,
- 92, 93, 94, '[', '\\', ']', '^', '_',
-'`', 65, 66, 67, 70, 72, 73, 74,
- 75, 76, 77, 78, 79, 80, 81, 82,
- 83, 84, 85, 86, 88, 89, 90, 91,
- 92, 93, 94, '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) 87,(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) 95,(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) 87,(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) 95,(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-'A', 'A', 'A', 'A', '\\', '[', 69, 'C',
- 68, 'E', 'E', 'E', 'I', 'I', 'I', 'I',
- 71, 'N', 'O', 'O', 'O', 'O', ']',(uchar) '\327',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y',(uchar) '\336',(uchar) '\337',
-'A', 'A', 'A', 'A', '\\', '[', 69, 'C',
- 68, 'E', 'E', 'E', 'I', 'I', 'I', 'I',
- 71, 'N', 'O', 'O', 'O', 'O', ']',(uchar) '\367',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y',(uchar) '\336',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-danish.c b/strings/Attic/ctype-danish.c
deleted file mode 100644
index 7b74c5cba15..00000000000
--- a/strings/Attic/ctype-danish.c
+++ /dev/null
@@ -1,144 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/*
-** This implements the ISO 8859 Latin1 character-set with danish sorting
-** This file is equivalent to ctype-latin1.c except for the last variable
-** (sort_order_danish)
-*/
-
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_danish[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_danish[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\327',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_danish[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-};
-
-#ifndef __WIN32__
-uchar NEAR sort_order_danish[]={
-#else
-uchar sort_order_danish[]={
-#endif
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-'A', 'A', 'A', 'A', '[', ']', '[', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', '\\', (uchar) '\327',
-'\\','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\337',
-'A', 'A', 'A', 'A', '[', ']', '[', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', '\\', (uchar) '\367',
-'\\','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-dec8.c b/strings/Attic/ctype-dec8.c
deleted file mode 100644
index f32302979eb..00000000000
--- a/strings/Attic/ctype-dec8.c
+++ /dev/null
@@ -1,140 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#include <global.h>
-#include "m_string.h"
-
-#define CTYPE /* initialize ctype arrays */
-#include "m_ctype.h"
-
-void init_ctype(void) /* Stupid linker !! */
-{} /* Some symbol must be defined */
-
-uchar ctype_dec8[257] =
-{
-0, /* For standard library */
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_dec8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\327',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_dec8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-};
-
-uchar NEAR sort_order_dec8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-'A', 'A', 'A', 'A', '\\', '[', '\\', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', ']', (uchar) '\327',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\337',
-'A', 'A', 'A', 'A', '\\', '[', '\\', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', ']', (uchar) '\367',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-dos.c b/strings/Attic/ctype-dos.c
deleted file mode 100644
index 0578a33bfd0..00000000000
--- a/strings/Attic/ctype-dos.c
+++ /dev/null
@@ -1,139 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#include <global.h>
-#include "m_string.h"
-
-#ifndef _WINDOWS
-uchar NEAR ctype[257] =
-{
- 0, /* For standard library */
- 32,48,48,48,48,48,48,32,32,40,40,40,40,40,48,48,
- 48,48,48,48,48,48,48,48,48,48,32,48,48,48,48,48,
- 72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
- 16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
- 1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
- 16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
- 2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,48,
-
- 2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,
- 1,2,1,2,2,2,2,2,2,1,1,16,16,16,16,16,
- 2,2,2,2,2,1,16,16,16,16,16,16,16,16,16,16,
- 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,32,
-};
-
-uchar NEAR to_lower[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '[', '\\', ']', '^', '_',
- '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '{', '|', '}', '~', '\177',
- 135, 129, 130, 131, 132, 133, 134, 135,
- 136, 137, 138, 139, 140, 141, 132, 134,
- 130, 145, 145, 147, 148, 149, 150, 151,
- 152, 148, 129, 155, 156, 157, 158, 159,
- 160, 161, 162, 163, 164, 164, 166, 167,
- 168, 169, 170, 171, 172, 173, 174, 175,
- 176, 177, 178, 179, 180, 181, 182, 183,
- 184, 185, 186, 187, 188, 189, 190, 191,
- 192, 193, 194, 195, 196, 197, 198, 199,
- 200, 201, 202, 203, 204, 205, 206, 207,
- 208, 209, 210, 211, 212, 213, 214, 215,
- 216, 217, 218, 219, 220, 221, 222, 223,
- 224, 225, 226, 227, 228, 229, 230, 231,
- 232, 233, 234, 235, 236, 237, 238, 239,
- 240, 241, 242, 243, 244, 245, 246, 247,
- 248, 249, 250, 251, 252, 253, 254, 255,
-};
-
-uchar NEAR to_upper[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
- '`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
- 128, 154, 144, 65, 142, 65, 143, 128,
- 69, 69, 69, 73, 73, 73, 142, 143,
- 144, 146, 146, 79, 153, 79, 85, 85,
- 89, 153, 154, 155, 156, 157, 158, 159,
- 65, 73, 79, 85, 165, 165, 166, 167,
- 168, 169, 170, 171, 172, 173, 174, 175,
- 176, 177, 178, 179, 180, 181, 182, 183,
- 184, 185, 186, 187, 188, 189, 190, 191,
- 192, 193, 194, 195, 196, 197, 198, 199,
- 200, 201, 202, 203, 204, 205, 206, 207,
- 208, 209, 210, 211, 212, 213, 214, 215,
- 216, 217, 218, 219, 220, 221, 222, 223,
- 224, 225, 226, 227, 228, 229, 230, 231,
- 232, 233, 234, 235, 236, 237, 238, 239,
- 240, 241, 242, 243, 244, 245, 246, 247,
- 248, 249, 250, 251, 252, 253, 254, 255,
-};
-
-uchar NEAR sort_order[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
- '`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
- 67, 89, 69, 65, 92, 65, 91, 67,
- 69, 69, 69, 73, 73, 73, 92, 91,
- 69, 92, 92, 79, 93, 79, 85, 85,
- 89, 93, 89, 36, 36, 36, 36, 36,
- 65, 73, 79, 85, 78, 78, 166, 167,
- 63, 169, 170, 171, 172, 33, 34, 34,
- 176, 177, 178, 179, 180, 181, 182, 183,
- 184, 185, 186, 187, 188, 189, 190, 191,
- 192, 193, 194, 195, 196, 197, 198, 199,
- 200, 201, 202, 203, 204, 205, 206, 207,
- 208, 209, 210, 211, 212, 213, 214, 215,
- 216, 217, 218, 219, 220, 221, 222, 223,
- 224, 225, 226, 227, 228, 229, 230, 231,
- 232, 233, 234, 235, 236, 237, 238, 239,
- 240, 241, 242, 243, 244, 245, 246, 247,
- 248, 249, 250, 251, 252, 253, 254, 255,
-};
-
-#endif
diff --git a/strings/Attic/ctype-estonia.c b/strings/Attic/ctype-estonia.c
deleted file mode 100644
index f17463583c9..00000000000
--- a/strings/Attic/ctype-estonia.c
+++ /dev/null
@@ -1,93 +0,0 @@
-/* See on Eesti character-set,
-mis on kasutatav koos iso-8859-1(Latin1) tähestikuga
-autor : Ülo Sõstra ylo@stat.vil.ee
-*/
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_estonia[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_estonia[]={
-0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
-31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
-46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
-61, 62, 63, 64, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106,
-107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119,
-120, 121, 122, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,
-103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
-116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128,
-129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141,
-142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154,
-155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167,
-184, 169, 186, 171, 172, 173, 174, 191, 176, 177, 178, 179, 180,
-181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 224, 225,
-226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238,
-239, 240, 241, 242, 243, 244, 245, 246, 215, 248, 249, 250, 251,
-252, 253, 254, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232,
-233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245,
-246, 247, 248, 249, 250, 251, 252, 253, 254, 255
-};
-
-uchar NEAR to_upper_estonia[]={
-0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
-31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
-46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
-61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
-76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,
-91, 92, 93, 94, 95, 96, 65, 66, 67, 68, 69, 70, 71, 72, 73,
-74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88,
-89, 90, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133,
-134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146,
-147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159,
-160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172,
-173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 168, 185,
-170, 187, 188, 189, 190, 175, 192, 193, 194, 195, 196, 197, 198,
-199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211,
-212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 192,
-193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205,
-206, 207, 208, 209, 210, 211, 212, 213, 214, 247, 216, 217, 218,
-219, 220, 221, 222, 255
-};
-
-#ifndef __WIN32__
-uchar NEAR sort_order_estonia[]={
-#else
-uchar sort_order_estonia[]={
-#endif
-0, 2, 3, 4, 5, 6, 7, 8, 9, 46, 47, 48, 49, 50, 10, 11, 12, 13, 14, 15,
-16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 44, 51, 52, 53, 54, 55,
-56, 39, 57, 58, 59, 93, 60, 40, 61, 62, 118, 122, 124, 126, 128, 129, 130,
-131, 132, 133, 63, 64, 94, 95, 96, 65, 66, 134, 144, 146, 152, 154, 164, 166,
-170, 172, 178, 180, 184, 190, 192, 198, 206, 208, 210, 214, 229, 232, 238, 240,
-250, 252, 221, 67, 68, 69, 70, 71, 72, 135, 145, 147, 153, 155, 165, 167, 171,
-173, 179, 181, 185, 191, 193, 199, 207, 209, 211, 215, 230, 233, 239, 241, 251,
-253, 222, 73, 74, 75, 76, 28, 1, 29, 87, 30, 90, 116, 113, 114, 31, 117, 32, 91,
-33, 78, 82, 81, 34, 85, 86, 88, 89, 115, 42, 43, 35, 231, 36, 92, 37, 79, 84, 38, 45,
-254, 102, 103, 104, 255, 77, 105, 204, 106, 212, 98, 107, 41, 108, 142, 109, 97, 125,
-127, 80, 110, 111, 112, 205, 123, 213, 99, 119, 120, 121, 143, 140, 176, 136, 148, 244,
-138, 162, 160, 150, 156, 223, 158, 168, 182, 174, 186, 219, 194, 196, 200, 202, 242, 246,
-100, 236, 188, 216, 234, 248, 225, 227, 218, 141, 177, 137, 149, 245, 139, 163, 161, 151,
-157, 224, 159, 169, 183, 175, 187, 220, 195, 197, 201, 203, 243, 247, 101, 237, 189, 217,
-235, 249, 226, 228, 83
-};
diff --git a/strings/Attic/ctype-german1.c b/strings/Attic/ctype-german1.c
deleted file mode 100755
index f767edc5f3d..00000000000
--- a/strings/Attic/ctype-german1.c
+++ /dev/null
@@ -1,135 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* This implements the ISO 8859 Latin1 (Modified for German) character-set */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_german1[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_german1[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\327',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_german1[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-};
-
-uchar NEAR sort_order_german1[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-'A', 'A', 'A', 'A', 'A', 'A', 'A', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', 'O', (uchar) '\327',
-(uchar) '\330','U', 'U', 'U', 'U', 'Y', (uchar) '\336',(uchar) '\337',
-'A', 'A', 'A', 'A', 'A', 'A', 'A', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', 'O', (uchar) '\367',
-(uchar) '\330','U', 'U', 'U', 'U', 'Y', (uchar) '\336',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-greek.c b/strings/Attic/ctype-greek.c
deleted file mode 100644
index 8d101687c91..00000000000
--- a/strings/Attic/ctype-greek.c
+++ /dev/null
@@ -1,855 +0,0 @@
-/* SCV: The content of this file is freeware.
- Use it or abuse it. I couldn't care less */
-
-/* This implements the ISO 8859-7 Greek character-set */
-/* See the end of this file for a definition of the set */
-
-#include <global.h>
-#include "m_string.h"
-
-/* some definitions first */
-#define GREEK_TONOS ((uchar)('\264')) /* 180 */
-#define GREEK_DIALYTIKA_TONOS ((uchar)('\265')) /* 181 */
-#define GREEK_CAPITAL_LETTER_ALPHA_WITH_TONOS ((uchar)('\266')) /* 182 */
-#define GREEK_CAPITAL_LETTER_EPSILON_WITH_TONOS ((uchar)('\270')) /* 184 */
-#define GREEK_CAPITAL_LETTER_ETA_WITH_TONOS ((uchar)('\271')) /* 185 */
-#define GREEK_CAPITAL_LETTER_IOTA_WITH_TONOS ((uchar)('\272')) /* 186 */
-#define GREEK_CAPITAL_LETTER_OMICRON_WITH_TONOS ((uchar)('\274')) /* 188 */
-#define GREEK_CAPITAL_LETTER_UPSILON_WITH_TONOS ((uchar)('\276')) /* 190 */
-#define GREEK_CAPITAL_LETTER_OMEGA_WITH_TONOS ((uchar)('\277')) /* 191 */
-#define GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA_AND_TONOS ((uchar)('\300')) /* 192 */
-#define GREEK_CAPITAL_LETTER_ALPHA ((uchar)('\301')) /* 193 */
-#define GREEK_CAPITAL_LETTER_BETA ((uchar)('\302')) /* 194 */
-#define GREEK_CAPITAL_LETTER_GAMMA ((uchar)('\303')) /* 195 */
-#define GREEK_CAPITAL_LETTER_DELTA ((uchar)('\304')) /* 196 */
-#define GREEK_CAPITAL_LETTER_EPSILON ((uchar)('\305')) /* 197 */
-#define GREEK_CAPITAL_LETTER_ZETA ((uchar)('\306')) /* 198 */
-#define GREEK_CAPITAL_LETTER_ETA ((uchar)('\307')) /* 199 */
-#define GREEK_CAPITAL_LETTER_THETA ((uchar)('\310')) /* 200 */
-#define GREEK_CAPITAL_LETTER_IOTA ((uchar)('\311')) /* 201 */
-#define GREEK_CAPITAL_LETTER_KAPPA ((uchar)('\312')) /* 202 */
-#define GREEK_CAPITAL_LETTER_LAMDA ((uchar)('\313')) /* 203 */
-#define GREEK_CAPITAL_LETTER_MU ((uchar)('\314')) /* 204 */
-#define GREEK_CAPITAL_LETTER_NU ((uchar)('\315')) /* 205 */
-#define GREEK_CAPITAL_LETTER_XI ((uchar)('\316')) /* 206 */
-#define GREEK_CAPITAL_LETTER_OMICRON ((uchar)('\317')) /* 207 */
-#define GREEK_CAPITAL_LETTER_PI ((uchar)('\320')) /* 208 */
-#define GREEK_CAPITAL_LETTER_RHO ((uchar)('\321')) /* 209 */
-#define GREEK_CAPITAL_LETTER_SIGMA ((uchar)('\323')) /* 211 */
-#define GREEK_CAPITAL_LETTER_TAU ((uchar)('\324')) /* 212 */
-#define GREEK_CAPITAL_LETTER_UPSILON ((uchar)('\325')) /* 213 */
-#define GREEK_CAPITAL_LETTER_PHI ((uchar)('\326')) /* 214 */
-#define GREEK_CAPITAL_LETTER_CHI ((uchar)('\327')) /* 215 */
-#define GREEK_CAPITAL_LETTER_PSI ((uchar)('\330')) /* 216 */
-#define GREEK_CAPITAL_LETTER_OMEGA ((uchar)('\331')) /* 217 */
-#define GREEK_CAPITAL_LETTER_IOTA_WITH_DIALYTIKA ((uchar)('\332')) /* 218 */
-#define GREEK_CAPITAL_LETTER_UPSILON_WITH_DIALYTIKA ((uchar)('\333')) /* 219 */
-#define GREEK_SMALL_LETTER_ALPHA_WITH_TONOS ((uchar)('\334')) /* 220 */
-#define GREEK_SMALL_LETTER_EPSILON_WITH_TONOS ((uchar)('\335')) /* 221 */
-#define GREEK_SMALL_LETTER_ETA_WITH_TONOS ((uchar)('\336')) /* 222 */
-#define GREEK_SMALL_LETTER_IOTA_WITH_TONOS ((uchar)('\337')) /* 223 */
-#define GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA_AND_TONOS ((uchar)('\340')) /* 224 */
-#define GREEK_SMALL_LETTER_ALPHA ((uchar)('\341')) /* 225 */
-#define GREEK_SMALL_LETTER_BETA ((uchar)('\342')) /* 226 */
-#define GREEK_SMALL_LETTER_GAMMA ((uchar)('\343')) /* 227 */
-#define GREEK_SMALL_LETTER_DELTA ((uchar)('\344')) /* 228 */
-#define GREEK_SMALL_LETTER_EPSILON ((uchar)('\345')) /* 229 */
-#define GREEK_SMALL_LETTER_ZETA ((uchar)('\346')) /* 230 */
-#define GREEK_SMALL_LETTER_ETA ((uchar)('\347')) /* 231 */
-#define GREEK_SMALL_LETTER_THETA ((uchar)('\350')) /* 232 */
-#define GREEK_SMALL_LETTER_IOTA ((uchar)('\351')) /* 233 */
-#define GREEK_SMALL_LETTER_KAPPA ((uchar)('\352')) /* 234 */
-#define GREEK_SMALL_LETTER_LAMDA ((uchar)('\353')) /* 235 */
-#define GREEK_SMALL_LETTER_MU ((uchar)('\354')) /* 236 */
-#define GREEK_SMALL_LETTER_NU ((uchar)('\355')) /* 237 */
-#define GREEK_SMALL_LETTER_XI ((uchar)('\356')) /* 238 */
-#define GREEK_SMALL_LETTER_OMICRON ((uchar)('\357')) /* 239 */
-#define GREEK_SMALL_LETTER_PI ((uchar)('\360')) /* 240 */
-#define GREEK_SMALL_LETTER_RHO ((uchar)('\361')) /* 241 */
-#define GREEK_SMALL_LETTER_FINAL_SIGMA ((uchar)('\362')) /* 242 */
-#define GREEK_SMALL_LETTER_SIGMA ((uchar)('\363')) /* 243 */
-#define GREEK_SMALL_LETTER_TAU ((uchar)('\364')) /* 244 */
-#define GREEK_SMALL_LETTER_UPSILON ((uchar)('\365')) /* 245 */
-#define GREEK_SMALL_LETTER_PHI ((uchar)('\366')) /* 246 */
-#define GREEK_SMALL_LETTER_CHI ((uchar)('\367')) /* 247 */
-#define GREEK_SMALL_LETTER_PSI ((uchar)('\370')) /* 248 */
-#define GREEK_SMALL_LETTER_OMEGA ((uchar)('\371')) /* 249 */
-#define GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA ((uchar)('\372')) /* 250 */
-#define GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA ((uchar)('\373')) /* 251 */
-#define GREEK_SMALL_LETTER_OMICRON_WITH_TONOS ((uchar)('\374')) /* 252 */
-#define GREEK_SMALL_LETTER_UPSILON_WITH_TONOS ((uchar)('\375')) /* 253 */
-#define GREEK_SMALL_LETTER_OMEGA_WITH_TONOS ((uchar)('\376')) /* 254 */
-
-uchar NEAR ctype_greek[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- /* 0 - 160 are the same as latin-1 */
-/* 160 */ 010 + 0100,
-/* 161 */ 020,
-/* 162 */ 020,
-/* 163 */ 020,
-/* 164 */ 0,
-/* 165 */ 0,
-/* 166 */ 020,
-/* 167 */ 020,
-/* 168 */ 020,
-/* 169 */ 020,
-/* 170 */ 0,
-/* 171 */ 020,
-/* 172 */ 020,
-/* 173 */ 020,
-/* 174 */ 0,
-/* 175 */ 020,
-/* 176 */ 020,
-/* 177 */ 020,
-/* 178 */ 020,
-/* 179 */ 020,
-/* 180 */ 020,
-/* 181 */ 020,
-/* 182 */ 01,
-/* 183 */ 020,
-/* 184 */ 01,
-/* 185 */ 01,
-/* 186 */ 01,
-/* 187 */ 020,
-/* 188 */ 01,
-/* 189 */ 020,
-/* 190 */ 01,
-/* 191 */ 01,
-/* 192 */ 02,
-/* 193 */ 01,
-/* 194 */ 01,
-/* 195 */ 01,
-/* 196 */ 01,
-/* 197 */ 01,
-/* 198 */ 01,
-/* 199 */ 01,
-/* 200 */ 01,
-/* 201 */ 01,
-/* 202 */ 01,
-/* 203 */ 01,
-/* 204 */ 01,
-/* 205 */ 01,
-/* 206 */ 01,
-/* 207 */ 01,
-/* 208 */ 01,
-/* 209 */ 01,
-/* 210 */ 0,
-/* 211 */ 01,
-/* 212 */ 01,
-/* 213 */ 01,
-/* 214 */ 01,
-/* 215 */ 01,
-/* 216 */ 01,
-/* 217 */ 01,
-/* 218 */ 01,
-/* 219 */ 01,
-/* 220 */ 02,
-/* 221 */ 02,
-/* 222 */ 02,
-/* 223 */ 02,
-/* 224 */ 02,
-/* 225 */ 02,
-/* 226 */ 02,
-/* 227 */ 02,
-/* 228 */ 02,
-/* 229 */ 02,
-/* 230 */ 02,
-/* 231 */ 02,
-/* 232 */ 02,
-/* 233 */ 02,
-/* 234 */ 02,
-/* 235 */ 02,
-/* 236 */ 02,
-/* 237 */ 02,
-/* 238 */ 02,
-/* 239 */ 02,
-/* 240 */ 02,
-/* 241 */ 02,
-/* 242 */ 02,
-/* 243 */ 02,
-/* 244 */ 02,
-/* 245 */ 02,
-/* 246 */ 02,
-/* 247 */ 02,
-/* 248 */ 02,
-/* 249 */ 02,
-/* 250 */ 02,
-/* 251 */ 02,
-/* 252 */ 02,
-/* 253 */ 02,
-/* 254 */ 02,
-/* 255 */ 0
-};
-
-uchar NEAR to_lower_greek[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-/* 128 */ (uchar)('\200'),
-/* 129 */ (uchar)('\201'),
-/* 130 */ (uchar)('\202'),
-/* 131 */ (uchar)('\203'),
-/* 132 */ (uchar)('\204'),
-/* 133 */ (uchar)('\205'),
-/* 134 */ (uchar)('\206'),
-/* 135 */ (uchar)('\207'),
-/* 136 */ (uchar)('\210'),
-/* 137 */ (uchar)('\211'),
-/* 138 */ (uchar)('\212'),
-/* 139 */ (uchar)('\213'),
-/* 140 */ (uchar)('\214'),
-/* 141 */ (uchar)('\215'),
-/* 142 */ (uchar)('\216'),
-/* 143 */ (uchar)('\217'),
-/* 144 */ (uchar)('\220'),
-/* 145 */ (uchar)('\221'),
-/* 146 */ (uchar)('\222'),
-/* 147 */ (uchar)('\223'),
-/* 148 */ (uchar)('\224'),
-/* 149 */ (uchar)('\225'),
-/* 150 */ (uchar)('\226'),
-/* 151 */ (uchar)('\227'),
-/* 152 */ (uchar)('\230'),
-/* 153 */ (uchar)('\231'),
-/* 154 */ (uchar)('\232'),
-/* 155 */ (uchar)('\233'),
-/* 156 */ (uchar)('\234'),
-/* 157 */ (uchar)('\235'),
-/* 158 */ (uchar)('\236'),
-/* 159 */ (uchar)('\237'),
-/* 160 */ (uchar)('\240'),
-/* 161 */ (uchar)('\241'),
-/* 162 */ (uchar)('\242'),
-/* 163 */ (uchar)('\243'),
-/* 164 */ (uchar)('\244'),
-/* 165 */ (uchar)('\245'),
-/* 166 */ (uchar)('\246'),
-/* 167 */ (uchar)('\247'),
-/* 168 */ (uchar)('\250'),
-/* 169 */ (uchar)('\251'),
-/* 170 */ (uchar)('\252'),
-/* 171 */ (uchar)('\253'),
-/* 172 */ (uchar)('\254'),
-/* 173 */ (uchar)('\255'),
-/* 174 */ (uchar)('\256'),
-/* 175 */ (uchar)('\257'),
-/* 176 */ (uchar)('\260'),
-/* 177 */ (uchar)('\261'),
-/* 178 */ (uchar)('\262'),
-/* 179 */ (uchar)('\263'),
-/* 180 */ GREEK_TONOS,
-/* 181 */ GREEK_DIALYTIKA_TONOS,
-/* 182 */ GREEK_SMALL_LETTER_ALPHA_WITH_TONOS,
-/* 183 */ (uchar)('\267'),
-/* 184 */ GREEK_SMALL_LETTER_EPSILON_WITH_TONOS,
-/* 185 */ GREEK_SMALL_LETTER_ETA_WITH_TONOS,
-/* 186 */ GREEK_SMALL_LETTER_IOTA_WITH_TONOS,
-/* 187 */ (uchar)('\273'),
-/* 188 */ GREEK_SMALL_LETTER_OMICRON_WITH_TONOS,
-/* 189 */ (uchar)('\275'),
-/* 190 */ GREEK_SMALL_LETTER_UPSILON_WITH_TONOS,
-/* 191 */ GREEK_SMALL_LETTER_OMEGA_WITH_TONOS,
-/* 192 */ GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA_AND_TONOS,
-/* 193 */ GREEK_SMALL_LETTER_ALPHA,
-/* 194 */ GREEK_SMALL_LETTER_BETA,
-/* 195 */ GREEK_SMALL_LETTER_GAMMA,
-/* 196 */ GREEK_SMALL_LETTER_DELTA,
-/* 197 */ GREEK_SMALL_LETTER_EPSILON,
-/* 198 */ GREEK_SMALL_LETTER_ZETA,
-/* 199 */ GREEK_SMALL_LETTER_ETA,
-/* 200 */ GREEK_SMALL_LETTER_THETA,
-/* 201 */ GREEK_SMALL_LETTER_IOTA,
-/* 202 */ GREEK_SMALL_LETTER_KAPPA,
-/* 203 */ GREEK_SMALL_LETTER_LAMDA,
-/* 204 */ GREEK_SMALL_LETTER_MU,
-/* 205 */ GREEK_SMALL_LETTER_NU,
-/* 206 */ GREEK_SMALL_LETTER_XI,
-/* 207 */ GREEK_SMALL_LETTER_OMICRON,
-/* 208 */ GREEK_SMALL_LETTER_PI,
-/* 209 */ GREEK_SMALL_LETTER_RHO,
-/* 210 */ (uchar)('\322'),
-/* 211 */ GREEK_SMALL_LETTER_SIGMA,
-/* 212 */ GREEK_SMALL_LETTER_TAU,
-/* 213 */ GREEK_SMALL_LETTER_UPSILON,
-/* 214 */ GREEK_SMALL_LETTER_PHI,
-/* 215 */ GREEK_SMALL_LETTER_CHI,
-/* 216 */ GREEK_SMALL_LETTER_PSI,
-/* 217 */ GREEK_SMALL_LETTER_OMEGA,
-/* 218 */ GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA,
-/* 219 */ GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA,
-/* 220 */ GREEK_SMALL_LETTER_ALPHA_WITH_TONOS,
-/* 221 */ GREEK_SMALL_LETTER_EPSILON_WITH_TONOS,
-/* 222 */ GREEK_SMALL_LETTER_ETA_WITH_TONOS,
-/* 223 */ GREEK_SMALL_LETTER_IOTA_WITH_TONOS,
-/* 224 */ GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA_AND_TONOS,
-/* 225 */ GREEK_SMALL_LETTER_ALPHA,
-/* 226 */ GREEK_SMALL_LETTER_BETA,
-/* 227 */ GREEK_SMALL_LETTER_GAMMA,
-/* 228 */ GREEK_SMALL_LETTER_DELTA,
-/* 229 */ GREEK_SMALL_LETTER_EPSILON,
-/* 230 */ GREEK_SMALL_LETTER_ZETA,
-/* 231 */ GREEK_SMALL_LETTER_ETA,
-/* 232 */ GREEK_SMALL_LETTER_THETA,
-/* 233 */ GREEK_SMALL_LETTER_IOTA,
-/* 234 */ GREEK_SMALL_LETTER_KAPPA,
-/* 235 */ GREEK_SMALL_LETTER_LAMDA,
-/* 236 */ GREEK_SMALL_LETTER_MU,
-/* 237 */ GREEK_SMALL_LETTER_NU,
-/* 238 */ GREEK_SMALL_LETTER_XI,
-/* 239 */ GREEK_SMALL_LETTER_OMICRON,
-/* 240 */ GREEK_SMALL_LETTER_PI,
-/* 241 */ GREEK_SMALL_LETTER_RHO,
-/* 242 */ GREEK_SMALL_LETTER_FINAL_SIGMA,
-/* 243 */ GREEK_SMALL_LETTER_SIGMA,
-/* 244 */ GREEK_SMALL_LETTER_TAU,
-/* 245 */ GREEK_SMALL_LETTER_UPSILON,
-/* 246 */ GREEK_SMALL_LETTER_PHI,
-/* 247 */ GREEK_SMALL_LETTER_CHI,
-/* 248 */ GREEK_SMALL_LETTER_PSI,
-/* 249 */ GREEK_SMALL_LETTER_OMEGA,
-/* 250 */ GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA,
-/* 251 */ GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA,
-/* 252 */ GREEK_SMALL_LETTER_OMICRON_WITH_TONOS,
-/* 253 */ GREEK_SMALL_LETTER_UPSILON_WITH_TONOS,
-/* 254 */ GREEK_SMALL_LETTER_OMEGA_WITH_TONOS,
-/* 255 */ (uchar)('\377')
-};
-
-uchar NEAR to_upper_greek[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-/* 128 */ (uchar)('\200'),
-/* 129 */ (uchar)('\201'),
-/* 130 */ (uchar)('\202'),
-/* 131 */ (uchar)('\203'),
-/* 132 */ (uchar)('\204'),
-/* 133 */ (uchar)('\205'),
-/* 134 */ (uchar)('\206'),
-/* 135 */ (uchar)('\207'),
-/* 136 */ (uchar)('\210'),
-/* 137 */ (uchar)('\211'),
-/* 138 */ (uchar)('\212'),
-/* 139 */ (uchar)('\213'),
-/* 140 */ (uchar)('\214'),
-/* 141 */ (uchar)('\215'),
-/* 142 */ (uchar)('\216'),
-/* 143 */ (uchar)('\217'),
-/* 144 */ (uchar)('\220'),
-/* 145 */ (uchar)('\221'),
-/* 146 */ (uchar)('\222'),
-/* 147 */ (uchar)('\223'),
-/* 148 */ (uchar)('\224'),
-/* 149 */ (uchar)('\225'),
-/* 150 */ (uchar)('\226'),
-/* 151 */ (uchar)('\227'),
-/* 152 */ (uchar)('\230'),
-/* 153 */ (uchar)('\231'),
-/* 154 */ (uchar)('\232'),
-/* 155 */ (uchar)('\233'),
-/* 156 */ (uchar)('\234'),
-/* 157 */ (uchar)('\235'),
-/* 158 */ (uchar)('\236'),
-/* 159 */ (uchar)('\237'),
-/* 160 */ (uchar)('\240'),
-/* 161 */ (uchar)('\241'),
-/* 162 */ (uchar)('\242'),
-/* 163 */ (uchar)('\243'),
-/* 164 */ (uchar)('\244'),
-/* 165 */ (uchar)('\245'),
-/* 166 */ (uchar)('\246'),
-/* 167 */ (uchar)('\247'),
-/* 168 */ (uchar)('\250'),
-/* 169 */ (uchar)('\251'),
-/* 170 */ (uchar)('\252'),
-/* 171 */ (uchar)('\253'),
-/* 172 */ (uchar)('\254'),
-/* 173 */ (uchar)('\255'),
-/* 174 */ (uchar)('\256'),
-/* 175 */ (uchar)('\257'),
-/* 176 */ (uchar)('\260'),
-/* 177 */ (uchar)('\261'),
-/* 178 */ (uchar)('\262'),
-/* 179 */ (uchar)('\263'),
-/* 180 */ GREEK_TONOS,
-/* 181 */ GREEK_DIALYTIKA_TONOS,
-/* 182 */ GREEK_CAPITAL_LETTER_ALPHA_WITH_TONOS,
-/* 183 */ (uchar)('\267'),
-/* 184 */ GREEK_CAPITAL_LETTER_EPSILON_WITH_TONOS,
-/* 185 */ GREEK_CAPITAL_LETTER_ETA_WITH_TONOS,
-/* 186 */ GREEK_CAPITAL_LETTER_IOTA_WITH_TONOS,
-/* 187 */ (uchar)('\273'),
-/* 188 */ GREEK_CAPITAL_LETTER_OMICRON_WITH_TONOS,
-/* 189 */ (uchar)('\275'),
-/* 190 */ GREEK_CAPITAL_LETTER_UPSILON_WITH_TONOS,
-/* 191 */ GREEK_CAPITAL_LETTER_OMEGA_WITH_TONOS,
-/* 192 */ GREEK_CAPITAL_LETTER_IOTA_WITH_DIALYTIKA,
-/* 193 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 194 */ GREEK_CAPITAL_LETTER_BETA,
-/* 195 */ GREEK_CAPITAL_LETTER_GAMMA,
-/* 196 */ GREEK_CAPITAL_LETTER_DELTA,
-/* 197 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 198 */ GREEK_CAPITAL_LETTER_ZETA,
-/* 199 */ GREEK_CAPITAL_LETTER_ETA,
-/* 200 */ GREEK_CAPITAL_LETTER_THETA,
-/* 201 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 202 */ GREEK_CAPITAL_LETTER_KAPPA,
-/* 203 */ GREEK_CAPITAL_LETTER_LAMDA,
-/* 204 */ GREEK_CAPITAL_LETTER_MU,
-/* 205 */ GREEK_CAPITAL_LETTER_NU,
-/* 206 */ GREEK_CAPITAL_LETTER_XI,
-/* 207 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 208 */ GREEK_CAPITAL_LETTER_PI,
-/* 209 */ GREEK_CAPITAL_LETTER_RHO,
-/* 210 */ (uchar)('\322'),
-/* 211 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 212 */ GREEK_CAPITAL_LETTER_TAU,
-/* 213 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 214 */ GREEK_CAPITAL_LETTER_PHI,
-/* 215 */ GREEK_CAPITAL_LETTER_CHI,
-/* 216 */ GREEK_CAPITAL_LETTER_PSI,
-/* 217 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 218 */ GREEK_CAPITAL_LETTER_IOTA_WITH_DIALYTIKA,
-/* 219 */ GREEK_CAPITAL_LETTER_UPSILON_WITH_DIALYTIKA,
-/* 220 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 221 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 222 */ GREEK_CAPITAL_LETTER_ETA,
-/* 223 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 224 */ GREEK_CAPITAL_LETTER_UPSILON_WITH_DIALYTIKA,
-/* 225 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 226 */ GREEK_CAPITAL_LETTER_BETA,
-/* 227 */ GREEK_CAPITAL_LETTER_GAMMA,
-/* 228 */ GREEK_CAPITAL_LETTER_DELTA,
-/* 229 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 230 */ GREEK_CAPITAL_LETTER_ZETA,
-/* 231 */ GREEK_CAPITAL_LETTER_ETA,
-/* 232 */ GREEK_CAPITAL_LETTER_THETA,
-/* 233 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 234 */ GREEK_CAPITAL_LETTER_KAPPA,
-/* 235 */ GREEK_CAPITAL_LETTER_LAMDA,
-/* 236 */ GREEK_CAPITAL_LETTER_MU,
-/* 237 */ GREEK_CAPITAL_LETTER_NU,
-/* 238 */ GREEK_CAPITAL_LETTER_XI,
-/* 239 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 240 */ GREEK_CAPITAL_LETTER_PI,
-/* 241 */ GREEK_CAPITAL_LETTER_RHO,
-/* 242 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 243 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 244 */ GREEK_CAPITAL_LETTER_TAU,
-/* 245 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 246 */ GREEK_CAPITAL_LETTER_PHI,
-/* 247 */ GREEK_CAPITAL_LETTER_CHI,
-/* 248 */ GREEK_CAPITAL_LETTER_PSI,
-/* 249 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 250 */ GREEK_CAPITAL_LETTER_IOTA_WITH_DIALYTIKA,
-/* 251 */ GREEK_CAPITAL_LETTER_UPSILON_WITH_DIALYTIKA,
-/* 252 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 253 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 254 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 255 */ (uchar)('\377')
-};
-
-uchar NEAR sort_order_greek[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',
- /* 0 - 180 are the same as latin-1 */
-/* 180 */ GREEK_TONOS,
-/* 181 */ GREEK_DIALYTIKA_TONOS,
-/* 182 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 183 */ (uchar)('\267'),
-/* 184 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 185 */ GREEK_CAPITAL_LETTER_ETA,
-/* 186 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 187 */ (uchar)('\273'),
-/* 188 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 189 */ (uchar)('\275'),
-/* 190 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 191 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 192 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 193 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 194 */ GREEK_CAPITAL_LETTER_BETA,
-/* 195 */ GREEK_CAPITAL_LETTER_GAMMA,
-/* 196 */ GREEK_CAPITAL_LETTER_DELTA,
-/* 197 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 198 */ GREEK_CAPITAL_LETTER_ZETA,
-/* 199 */ GREEK_CAPITAL_LETTER_ETA,
-/* 200 */ GREEK_CAPITAL_LETTER_THETA,
-/* 201 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 202 */ GREEK_CAPITAL_LETTER_KAPPA,
-/* 203 */ GREEK_CAPITAL_LETTER_LAMDA,
-/* 204 */ GREEK_CAPITAL_LETTER_MU,
-/* 205 */ GREEK_CAPITAL_LETTER_NU,
-/* 206 */ GREEK_CAPITAL_LETTER_XI,
-/* 207 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 208 */ GREEK_CAPITAL_LETTER_PI,
-/* 209 */ GREEK_CAPITAL_LETTER_RHO,
-/* 210 */ (uchar)('\322'),
-/* 211 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 212 */ GREEK_CAPITAL_LETTER_TAU,
-/* 213 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 214 */ GREEK_CAPITAL_LETTER_PHI,
-/* 215 */ GREEK_CAPITAL_LETTER_CHI,
-/* 216 */ GREEK_CAPITAL_LETTER_PSI,
-/* 217 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 218 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 219 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 220 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 221 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 222 */ GREEK_CAPITAL_LETTER_ETA,
-/* 223 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 224 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 225 */ GREEK_CAPITAL_LETTER_ALPHA,
-/* 226 */ GREEK_CAPITAL_LETTER_BETA,
-/* 227 */ GREEK_CAPITAL_LETTER_GAMMA,
-/* 228 */ GREEK_CAPITAL_LETTER_DELTA,
-/* 229 */ GREEK_CAPITAL_LETTER_EPSILON,
-/* 230 */ GREEK_CAPITAL_LETTER_ZETA,
-/* 231 */ GREEK_CAPITAL_LETTER_ETA,
-/* 232 */ GREEK_CAPITAL_LETTER_THETA,
-/* 233 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 234 */ GREEK_CAPITAL_LETTER_KAPPA,
-/* 235 */ GREEK_CAPITAL_LETTER_LAMDA,
-/* 236 */ GREEK_CAPITAL_LETTER_MU,
-/* 237 */ GREEK_CAPITAL_LETTER_NU,
-/* 238 */ GREEK_CAPITAL_LETTER_XI,
-/* 239 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 240 */ GREEK_CAPITAL_LETTER_PI,
-/* 241 */ GREEK_CAPITAL_LETTER_RHO,
-/* 242 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 243 */ GREEK_CAPITAL_LETTER_SIGMA,
-/* 244 */ GREEK_CAPITAL_LETTER_TAU,
-/* 245 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 246 */ GREEK_CAPITAL_LETTER_PHI,
-/* 247 */ GREEK_CAPITAL_LETTER_CHI,
-/* 248 */ GREEK_CAPITAL_LETTER_PSI,
-/* 249 */ GREEK_CAPITAL_LETTER_OMEGA,
-/* 250 */ GREEK_CAPITAL_LETTER_IOTA,
-/* 251 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 252 */ GREEK_CAPITAL_LETTER_OMICRON,
-/* 253 */ GREEK_CAPITAL_LETTER_UPSILON,
-/* 254 */ GREEK_CAPITAL_LETTER_OMEGA,
-(uchar) '\377'
-};
-
-/* let's clean after ourselves */
-#undef GREEK_TONOS
-#undef GREEK_DIALYTIKA_TONOS
-#undef GREEK_CAPITAL_LETTER_ALPHA_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_EPSILON_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_ETA_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_IOTA_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_OMICRON_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_UPSILON_WITH_TONOS
-#undef GREEK_CAPITAL_LETTER_OMEGA_WITH_TONOS
-#undef GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA_AND_TONOS
-#undef GREEK_CAPITAL_LETTER_ALPHA
-#undef GREEK_CAPITAL_LETTER_BETA
-#undef GREEK_CAPITAL_LETTER_GAMMA
-#undef GREEK_CAPITAL_LETTER_DELTA
-#undef GREEK_CAPITAL_LETTER_EPSILON
-#undef GREEK_CAPITAL_LETTER_ZETA
-#undef GREEK_CAPITAL_LETTER_ETA
-#undef GREEK_CAPITAL_LETTER_THETA
-#undef GREEK_CAPITAL_LETTER_IOTA
-#undef GREEK_CAPITAL_LETTER_KAPPA
-#undef GREEK_CAPITAL_LETTER_LAMDA
-#undef GREEK_CAPITAL_LETTER_MU
-#undef GREEK_CAPITAL_LETTER_NU
-#undef GREEK_CAPITAL_LETTER_XI
-#undef GREEK_CAPITAL_LETTER_OMICRON
-#undef GREEK_CAPITAL_LETTER_PI
-#undef GREEK_CAPITAL_LETTER_RHO
-#undef GREEK_CAPITAL_LETTER_SIGMA
-#undef GREEK_CAPITAL_LETTER_TAU
-#undef GREEK_CAPITAL_LETTER_UPSILON
-#undef GREEK_CAPITAL_LETTER_PHI
-#undef GREEK_CAPITAL_LETTER_CHI
-#undef GREEK_CAPITAL_LETTER_PSI
-#undef GREEK_CAPITAL_LETTER_OMEGA
-#undef GREEK_CAPITAL_LETTER_IOTA_WITH_DIALYTIKA
-#undef GREEK_CAPITAL_LETTER_UPSILON_WITH_DIALYTIKA
-#undef GREEK_SMALL_LETTER_ALPHA_WITH_TONOS
-#undef GREEK_SMALL_LETTER_EPSILON_WITH_TONOS
-#undef GREEK_SMALL_LETTER_ETA_WITH_TONOS
-#undef GREEK_SMALL_LETTER_IOTA_WITH_TONOS
-#undef GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA_AND_TONOS ((uchar)('\340')) /* 224 */
-#undef GREEK_SMALL_LETTER_ALPHA
-#undef GREEK_SMALL_LETTER_BETA
-#undef GREEK_SMALL_LETTER_GAMMA
-#undef GREEK_SMALL_LETTER_DELTA
-#undef GREEK_SMALL_LETTER_EPSILON
-#undef GREEK_SMALL_LETTER_ZETA
-#undef GREEK_SMALL_LETTER_ETA
-#undef GREEK_SMALL_LETTER_THETA
-#undef GREEK_SMALL_LETTER_IOTA
-#undef GREEK_SMALL_LETTER_KAPPA
-#undef GREEK_SMALL_LETTER_LAMDA
-#undef GREEK_SMALL_LETTER_MU
-#undef GREEK_SMALL_LETTER_NU
-#undef GREEK_SMALL_LETTER_XI
-#undef GREEK_SMALL_LETTER_OMICRON
-#undef GREEK_SMALL_LETTER_PI
-#undef GREEK_SMALL_LETTER_RHO
-#undef GREEK_SMALL_LETTER_FINAL_SIGMA
-#undef GREEK_SMALL_LETTER_SIGMA
-#undef GREEK_SMALL_LETTER_TAU
-#undef GREEK_SMALL_LETTER_UPSILON
-#undef GREEK_SMALL_LETTER_PHI
-#undef GREEK_SMALL_LETTER_CHI
-#undef GREEK_SMALL_LETTER_PSI
-#undef GREEK_SMALL_LETTER_OMEGA
-#undef GREEK_SMALL_LETTER_IOTA_WITH_DIALYTIKA
-#undef GREEK_SMALL_LETTER_UPSILON_WITH_DIALYTIKA
-#undef GREEK_SMALL_LETTER_OMICRON_WITH_TONOS
-#undef GREEK_SMALL_LETTER_UPSILON_WITH_TONOS
-#undef GREEK_SMALL_LETTER_OMEGA_WITH_TONOS
-
-#if 0
-ISO 8859-7 (Latin/Greek Alphabet)
-Dec Hex ISO/IEC 10646-1:1993(E) Character Name
- 32 20 SPACE
- 33 21 EXCLAMATION MARK
- 34 22 QUOTATION MARK
- 35 23 NUMBER SIGN
- 36 24 DOLLAR SIGN
- 37 25 PERCENT SIGN
- 38 26 AMPERSAND
- 39 27 APOSTROPHE
- 40 28 LEFT PARENTHESIS
- 41 29 RIGHT PARENTHESIS
- 42 2A ASTERISK
- 43 2B PLUS SIGN
- 44 2C COMMA
- 45 2D HYPHEN-MINUS
- 46 2E FULL STOP
- 47 2F SOLIDUS
- 48 30 DIGIT ZERO
- 49 31 DIGIT ONE
- 50 32 DIGIT TWO
- 51 33 DIGIT THREE
- 52 34 DIGIT FOUR
- 53 35 DIGIT FIVE
- 54 36 DIGIT SIX
- 55 37 DIGIT SEVEN
- 56 38 DIGIT EIGHT
- 57 39 DIGIT NINE
- 58 3A COLON
- 59 3B SEMICOLON
- 60 3C LESS-THAN SIGN
- 61 3D EQUALS SIGN
- 62 3E GREATER-THAN SIGN
- 63 3F QUESTION MARK
- 64 40 COMMERCIAL AT
- 65 41 LATIN CAPITAL LETTER A
- 66 42 LATIN CAPITAL LETTER B
- 67 43 LATIN CAPITAL LETTER C
- 68 44 LATIN CAPITAL LETTER D
- 69 45 LATIN CAPITAL LETTER E
- 70 46 LATIN CAPITAL LETTER F
- 71 47 LATIN CAPITAL LETTER G
- 72 48 LATIN CAPITAL LETTER H
- 73 49 LATIN CAPITAL LETTER I
- 74 4A LATIN CAPITAL LETTER J
- 75 4B LATIN CAPITAL LETTER K
- 76 4C LATIN CAPITAL LETTER L
- 77 4D LATIN CAPITAL LETTER M
- 78 4E LATIN CAPITAL LETTER N
- 79 4F LATIN CAPITAL LETTER O
- 80 50 LATIN CAPITAL LETTER P
- 81 51 LATIN CAPITAL LETTER Q
- 82 52 LATIN CAPITAL LETTER R
- 83 53 LATIN CAPITAL LETTER S
- 84 54 LATIN CAPITAL LETTER T
- 85 55 LATIN CAPITAL LETTER U
- 86 56 LATIN CAPITAL LETTER V
- 87 57 LATIN CAPITAL LETTER W
- 88 58 LATIN CAPITAL LETTER X
- 89 59 LATIN CAPITAL LETTER Y
- 90 5A LATIN CAPITAL LETTER Z
- 91 5B LEFT SQUARE BRACKET
- 92 5C REVERSE SOLIDUS
- 93 5D RIGHT SQUARE BRACKET
- 94 5E CIRCUMFLEX ACCENT
- 95 5F LOW LINE
- 96 60 GRAVE ACCENT
- 97 61 LATIN SMALL LETTER A
- 98 62 LATIN SMALL LETTER B
- 99 63 LATIN SMALL LETTER C
-100 64 LATIN SMALL LETTER D
-101 65 LATIN SMALL LETTER E
-102 66 LATIN SMALL LETTER F
-103 67 LATIN SMALL LETTER G
-104 68 LATIN SMALL LETTER H
-105 69 LATIN SMALL LETTER I
-106 6A LATIN SMALL LETTER J
-107 6B LATIN SMALL LETTER K
-108 6C LATIN SMALL LETTER L
-109 6D LATIN SMALL LETTER M
-110 6E LATIN SMALL LETTER N
-111 6F LATIN SMALL LETTER O
-112 70 LATIN SMALL LETTER P
-113 71 LATIN SMALL LETTER Q
-114 72 LATIN SMALL LETTER R
-115 73 LATIN SMALL LETTER S
-116 74 LATIN SMALL LETTER T
-117 75 LATIN SMALL LETTER U
-118 76 LATIN SMALL LETTER V
-119 77 LATIN SMALL LETTER W
-120 78 LATIN SMALL LETTER X
-121 79 LATIN SMALL LETTER Y
-122 7A LATIN SMALL LETTER Z
-123 7B LEFT CURLY BRACKET
-124 7C VERTICAL LINE
-125 7D RIGHT CURLY BRACKET
-126 7E TILDE
-160 A0 NO-BREAK SPACE
-161 A1 LEFT SINGLE QUOTATION MARK
-162 A2 RIGHT SINGLE QUOTATION MARK
-163 A3 POUND SIGN
-166 A6 BROKEN BAR
-167 A7 SECTION SIGN
-168 A8 DIAERESIS
-169 A9 COPYRIGHT SIGN
-171 AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK
-172 AC NOT SIGN
-173 AD SOFT HYPHEN
-175 AF HORIZONTAL BAR
-176 B0 DEGREE SIGN
-177 B1 PLUS-MINUS SIGN
-178 B2 SUPERSCRIPT TWO
-179 B3 SUPERSCRIPT THREE
-180 B4 GREEK TONOS
-181 B5 GREEK DIALYTIKA TONOS
-182 B6 GREEK CAPITAL LETTER ALPHA WITH TONOS
-183 B7 MIDDLE DOT
-184 B8 GREEK CAPITAL LETTER EPSILON WITH TONOS
-185 B9 GREEK CAPITAL LETTER ETA WITH TONOS
-186 BA GREEK CAPITAL LETTER IOTA WITH TONOS
-187 BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK
-188 BC GREEK CAPITAL LETTER OMICRON WITH TONOS
-189 BD VULGAR FRACTION ONE HALF
-190 BE GREEK CAPITAL LETTER UPSILON WITH TONOS
-191 BF GREEK CAPITAL LETTER OMEGA WITH TONOS
-192 C0 GREEK SMALL LETTER IOTA WITH DIALYTIKA AND TONOS
-193 C1 GREEK CAPITAL LETTER ALPHA
-194 C2 GREEK CAPITAL LETTER BETA
-195 C3 GREEK CAPITAL LETTER GAMMA
-196 C4 GREEK CAPITAL LETTER DELTA
-197 C5 GREEK CAPITAL LETTER EPSILON
-198 C6 GREEK CAPITAL LETTER ZETA
-199 C7 GREEK CAPITAL LETTER ETA
-200 C8 GREEK CAPITAL LETTER THETA
-201 C9 GREEK CAPITAL LETTER IOTA
-202 CA GREEK CAPITAL LETTER KAPPA
-203 CB GREEK CAPITAL LETTER LAMDA
-204 CC GREEK CAPITAL LETTER MU
-205 CD GREEK CAPITAL LETTER NU
-206 CE GREEK CAPITAL LETTER XI
-207 CF GREEK CAPITAL LETTER OMICRON
-208 D0 GREEK CAPITAL LETTER PI
-209 D1 GREEK CAPITAL LETTER RHO
-211 D3 GREEK CAPITAL LETTER SIGMA
-212 D4 GREEK CAPITAL LETTER TAU
-213 D5 GREEK CAPITAL LETTER UPSILON
-214 D6 GREEK CAPITAL LETTER PHI
-215 D7 GREEK CAPITAL LETTER CHI
-216 D8 GREEK CAPITAL LETTER PSI
-217 D9 GREEK CAPITAL LETTER OMEGA
-218 DA GREEK CAPITAL LETTER IOTA WITH DIALYTIKA
-219 DB GREEK CAPITAL LETTER UPSILON WITH DIALYTIKA
-220 DC GREEK SMALL LETTER ALPHA WITH TONOS
-221 DD GREEK SMALL LETTER EPSILON WITH TONOS
-222 DE GREEK SMALL LETTER ETA WITH TONOS
-223 DF GREEK SMALL LETTER IOTA WITH TONOS
-224 E0 GREEK SMALL LETTER UPSILON WITH DIALYTIKA AND TONOS
-225 E1 GREEK SMALL LETTER ALPHA
-226 E2 GREEK SMALL LETTER BETA
-227 E3 GREEK SMALL LETTER GAMMA
-228 E4 GREEK SMALL LETTER DELTA
-229 E5 GREEK SMALL LETTER EPSILON
-230 E6 GREEK SMALL LETTER ZETA
-231 E7 GREEK SMALL LETTER ETA
-232 E8 GREEK SMALL LETTER THETA
-233 E9 GREEK SMALL LETTER IOTA
-234 EA GREEK SMALL LETTER KAPPA
-235 EB GREEK SMALL LETTER LAMDA
-236 EC GREEK SMALL LETTER MU
-237 ED GREEK SMALL LETTER NU
-238 EE GREEK SMALL LETTER XI
-239 EF GREEK SMALL LETTER OMICRON
-240 F0 GREEK SMALL LETTER PI
-241 F1 GREEK SMALL LETTER RHO
-242 F2 GREEK SMALL LETTER FINAL SIGMA
-243 F3 GREEK SMALL LETTER SIGMA
-244 F4 GREEK SMALL LETTER TAU
-245 F5 GREEK SMALL LETTER UPSILON
-246 F6 GREEK SMALL LETTER PHI
-247 F7 GREEK SMALL LETTER CHI
-248 F8 GREEK SMALL LETTER PSI
-249 F9 GREEK SMALL LETTER OMEGA
-250 FA GREEK SMALL LETTER IOTA WITH DIALYTIKA
-251 FB GREEK SMALL LETTER UPSILON WITH DIALYTIKA
-252 FC GREEK SMALL LETTER OMICRON WITH TONOS
-253 FD GREEK SMALL LETTER UPSILON WITH TONOS
-254 FE GREEK SMALL LETTER OMEGA WITH TONOS
-#endif
diff --git a/strings/Attic/ctype-hebrew.c b/strings/Attic/ctype-hebrew.c
deleted file mode 100644
index b1566b2bbe4..00000000000
--- a/strings/Attic/ctype-hebrew.c
+++ /dev/null
@@ -1,135 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* This implements the ISO 8859 Latin1 character-set */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_hebrew[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,0,0,0,0,0,
-};
-
-uchar NEAR to_lower_hebrew[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_hebrew[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR sort_order_hebrew[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-hp8.c b/strings/Attic/ctype-hp8.c
deleted file mode 100644
index 6397c3cb974..00000000000
--- a/strings/Attic/ctype-hp8.c
+++ /dev/null
@@ -1,133 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_hp8[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,32,32,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,2,16,16,16,16,16,16,2,16,2,2,
-1,16,16,1,2,16,16,2,1,16,1,1,1,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,32,32,32,32,16,16,16,16,16,16,16,16,16,32,
-};
-
-uchar NEAR to_lower_hp8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\310',(uchar) '\300',(uchar) '\311',(uchar) '\301',(uchar) '\315',(uchar) '\321',(uchar) '\335',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\313',(uchar) '\303',(uchar) '\257',
-(uchar) '\260',(uchar) '\262',(uchar) '\262',(uchar) '\263',(uchar) '\265',(uchar) '\265',(uchar) '\267',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\324',(uchar) '\321',(uchar) '\326',(uchar) '\327',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\314',(uchar) '\331',(uchar) '\316',(uchar) '\317',(uchar) '\305',(uchar) '\335',(uchar) '\336',(uchar) '\302',
-(uchar) '\304',(uchar) '\342',(uchar) '\342',(uchar) '\344',(uchar) '\344',(uchar) '\325',(uchar) '\331',(uchar) '\306',
-(uchar) '\312',(uchar) '\352',(uchar) '\352',(uchar) '\354',(uchar) '\354',(uchar) '\307',(uchar) '\357',(uchar) '\357',
-(uchar) '\361',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_hp8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\261',(uchar) '\263',(uchar) '\264',(uchar) '\264',(uchar) '\266',(uchar) '\266',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\242',(uchar) '\244',(uchar) '\337',(uchar) '\256',(uchar) '\340',(uchar) '\334',(uchar) '\347',(uchar) '\355',
-(uchar) '\241',(uchar) '\243',(uchar) '\350',(uchar) '\255',(uchar) '\330',(uchar) '\245',(uchar) '\332',(uchar) '\333',
-(uchar) '\320',(uchar) '\246',(uchar) '\322',(uchar) '\323',(uchar) '\320',(uchar) '\345',(uchar) '\322',(uchar) '\323',
-(uchar) '\330',(uchar) '\346',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\247',(uchar) '\336',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\341',(uchar) '\343',(uchar) '\343',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\351',(uchar) '\353',(uchar) '\353',(uchar) '\355',(uchar) '\356',(uchar) '\356',
-(uchar) '\360',(uchar) '\360',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR sort_order_hp8[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '\\', ']', '[', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-hungarian.c b/strings/Attic/ctype-hungarian.c
deleted file mode 100644
index 548c87f0d49..00000000000
--- a/strings/Attic/ctype-hungarian.c
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * File generated by cset
- * (C) Abandoned 1998 Zoltan Klar <klarz@svr-sun.ktg.gau.hu>
- * (C) 1999 é,ö sort order corrected by Huba Gaspar <huba@unixoft.hu>
- * This file is based on ctype-latin2.c
- *
- * n a g y k i c s i sort
- * kod
- * A' 143 181 193 160 225 67 ==a, ha == 65
- * E' 144 201 130 233 79 ==e, ha == 78
- * I' 141 140 205 161 237 86 ==i
- * O" 167 138 213 147 139 245 103
- * O' 149 224 211 162 243 100 ==o
- * O: 153 214 148 246 103
- * U" 152 235 219 150 251 120
- * U' 151 218 163 250 117 ==u
- * U: 154 220 129 252 120
- */
-#define hungarian_AA_EE
-/* megadása esetén az A és Á, valamint az E és az É nincs megkülönböztetve
- * a rendezés szempomtjából
- */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_hungarian[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 72,
- 1, 16, 1, 16, 1, 1, 16, 0, 0, 1, 1, 1, 1, 16, 1, 1,
- 16, 2, 16, 2, 16, 2, 2, 16, 16, 2, 2, 2, 2, 16, 2, 2,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 16, 1, 1, 1, 1, 1, 1, 16, 1, 1, 1, 1, 1, 1, 1, 16,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16, 2, 2, 2, 2, 2, 2, 2, 16
-};
-
-uchar NEAR to_lower_hungarian[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,139,139,161,161,142,160,
-130,145,146,147,148,162,150,163,150,148,129,155,156,157,158,159,
-160,161,162,163,181,182,166,147,168,185,186,187,188,173,190,191,
-176,177,178,179,180,225,182,183,184,185,186,187,188,189,190,191,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-208,241,242,243,244,245,246,215,248,249,250,251,252,253,254,223,
-162,225,226,227,228,229,230,231,232,233,234,150,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255
-};
-
-uchar NEAR to_upper_hungarian[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
-128,154,144,131,132,133,134,135,136,137,138,138,140,141,142,143,
-144,145,146,167,153,149,152,151,152,153,154,155,156,157,158,159,
-143,141,149,151,164,165,166,167,168,169,170,171,172,173,174,175,
-176,160,178,162,180,181,165,183,184,169,170,171,172,189,174,175,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-224,193,194,195,196,197,198,199,200,201,202,235,204,205,206,207,
-240,209,210,211,212,213,214,247,216,217,218,219,220,221,222,255
-};
-
-uchar NEAR sort_order_hungarian[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 71, 72, 76, 78, 83, 84, 85, 86, 90, 91, 92, 96, 97,100,
-105,106,107,110,114,117,122,123,124,125,127,131,132,133,134,135,
-136, 65, 71, 72, 76, 78, 83, 84, 85, 86, 90, 91, 92, 96, 97,100,
-105,106,107,110,114,117,122,123,124,125,127,137,138,139,140, 0,
-#ifdef hungarian_AA_EE
- 1,120, 78, 4, 5, 6, 7, 8, 9, 10,103,103, 86, 86, 15, 65,
- 78, 18, 19,103,103,100,120,117,120,103,120, 28, 29, 30, 31,255,
- 65, 86,100,117, 94,111,255,103,255,112,113,115,128,255,129,130,
-255, 66,255, 93,255, 65,111,255,255,112,113,115,128,255,129,130,
-108, 65, 68, 69, 70, 95, 73, 75, 74, 78, 81, 82, 80, 86, 87, 77,
-255, 98, 99,100,102,103,103,255,109,119,117,120,120,126,116,255,
-100, 65, 68, 69, 70, 95, 73, 75, 74, 78, 81,120, 80, 86, 88, 77,
-255, 98, 99,100,102,103,103,255,109,119,117,120,120,126,116,255
-#else
- 1,120, 79, 4, 5, 6, 7, 8, 9, 10,103,103, 86, 86, 15, 67,
- 79, 18, 19,103,103,100,120,117,120,103,120, 28, 29, 30, 31,255,
- 67, 86,100,117, 94,111,255,103,255,112,113,115,128,255,129,130,
-255, 66,255, 93,255, 67,111,255,255,112,113,115,128,255,129,130,
-108, 67, 68, 69, 70, 95, 73, 75, 74, 79, 81, 82, 80, 86, 87, 77,
-255, 98, 99,100,102,103,103,255,109,119,117,120,120,126,116,255,
-100, 67, 68, 69, 70, 95, 73, 75, 74, 79, 81,120, 80, 86, 88, 77,
-255, 98, 99,100,102,103,103,255,109,119,117,120,120,126,116,255
-#endif
-};
diff --git a/strings/Attic/ctype-koi8_ru.c b/strings/Attic/ctype-koi8_ru.c
deleted file mode 100644
index 6619e5322e6..00000000000
--- a/strings/Attic/ctype-koi8_ru.c
+++ /dev/null
@@ -1,133 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_koi8_ru[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,2,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,1,16,16,16,16,16,16,16,16,16,16,16,16,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-};
-
-uchar NEAR to_lower_koi8_ru[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\243',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-};
-
-uchar NEAR to_upper_koi8_ru[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\263',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR sort_order_koi8_ru[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\345',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',
-(uchar) '\247',(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',
-(uchar) '\257',(uchar) '\260',(uchar) '\261',(uchar) '\345',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',
-(uchar) '\266',(uchar) '\267',(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',
-(uchar) '\376',(uchar) '\337',(uchar) '\340',(uchar) '\366',(uchar) '\343',(uchar) '\344',(uchar) '\364',(uchar) '\342',
-(uchar) '\365',(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',
-(uchar) '\357',(uchar) '\377',(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\346',(uchar) '\341',
-(uchar) '\374',(uchar) '\373',(uchar) '\347',(uchar) '\370',(uchar) '\375',(uchar) '\371',(uchar) '\367',(uchar) '\372',
-(uchar) '\376',(uchar) '\337',(uchar) '\340',(uchar) '\366',(uchar) '\343',(uchar) '\344',(uchar) '\364',(uchar) '\342',
-(uchar) '\365',(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',
-(uchar) '\357',(uchar) '\377',(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\346',(uchar) '\341',
-(uchar) '\374',(uchar) '\373',(uchar) '\347',(uchar) '\370',(uchar) '\375',(uchar) '\371',(uchar) '\367',(uchar) '\372',
-};
diff --git a/strings/Attic/ctype-koi8_ukr.c b/strings/Attic/ctype-koi8_ukr.c
deleted file mode 100644
index d318e026f3a..00000000000
--- a/strings/Attic/ctype-koi8_ukr.c
+++ /dev/null
@@ -1,141 +0,0 @@
-//Created by Max Veremayenko (verem@tg.kiev.ua)
-//As standart for ukranian font i use ukrainian koi8 for KSI linux
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_koi8_ukr[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\2',(uchar)'\2',(uchar)'\20',(uchar)'\2',(uchar)'\2',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\2',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\1',(uchar)'\1',(uchar)'\20',(uchar)'\1',(uchar)'\1',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\1',(uchar)'\20',(uchar)'\20',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-};
-
-uchar NEAR to_lower_koi8_ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-' ', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\243',(uchar)'\244',(uchar)'\40',(uchar)'\246',(uchar)'\247',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\255',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\243',(uchar)'\244',(uchar)'\40',(uchar)'\246',(uchar)'\247',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\255',(uchar)'\40',(uchar)'\40',
-(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',(uchar)'\305',(uchar)'\306',(uchar)'\307',
-(uchar)'\310',(uchar)'\311',(uchar)'\312',(uchar)'\313',(uchar)'\314',(uchar)'\315',(uchar)'\316',(uchar)'\317',
-(uchar)'\320',(uchar)'\321',(uchar)'\322',(uchar)'\323',(uchar)'\324',(uchar)'\325',(uchar)'\326',(uchar)'\327',
-(uchar)'\330',(uchar)'\331',(uchar)'\332',(uchar)'\333',(uchar)'\334',(uchar)'\335',(uchar)'\336',(uchar)'\337',
-(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',(uchar)'\305',(uchar)'\306',(uchar)'\307',
-(uchar)'\310',(uchar)'\311',(uchar)'\312',(uchar)'\313',(uchar)'\314',(uchar)'\315',(uchar)'\316',(uchar)'\317',
-(uchar)'\320',(uchar)'\321',(uchar)'\322',(uchar)'\323',(uchar)'\324',(uchar)'\325',(uchar)'\326',(uchar)'\327',
-(uchar)'\330',(uchar)'\331',(uchar)'\332',(uchar)'\333',(uchar)'\334',(uchar)'\335',(uchar)'\336',(uchar)'\337',
-};
-
-uchar NEAR to_upper_koi8_ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-' ', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\263',(uchar)'\264',(uchar)'\40',(uchar)'\266',(uchar)'\267',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\275',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\263',(uchar)'\264',(uchar)'\40',(uchar)'\266',(uchar)'\267',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\275',(uchar)'\40',(uchar)'\40',
-(uchar)'\340',(uchar)'\341',(uchar)'\342',(uchar)'\343',(uchar)'\344',(uchar)'\345',(uchar)'\346',(uchar)'\347',
-(uchar)'\350',(uchar)'\351',(uchar)'\352',(uchar)'\353',(uchar)'\354',(uchar)'\355',(uchar)'\356',(uchar)'\357',
-(uchar)'\360',(uchar)'\361',(uchar)'\362',(uchar)'\363',(uchar)'\364',(uchar)'\365',(uchar)'\366',(uchar)'\367',
-(uchar)'\370',(uchar)'\371',(uchar)'\372',(uchar)'\373',(uchar)'\374',(uchar)'\375',(uchar)'\376',(uchar)'\377',
-(uchar)'\340',(uchar)'\341',(uchar)'\342',(uchar)'\343',(uchar)'\344',(uchar)'\345',(uchar)'\346',(uchar)'\347',
-(uchar)'\350',(uchar)'\351',(uchar)'\352',(uchar)'\353',(uchar)'\354',(uchar)'\355',(uchar)'\356',(uchar)'\357',
-(uchar)'\360',(uchar)'\361',(uchar)'\362',(uchar)'\363',(uchar)'\364',(uchar)'\365',(uchar)'\366',(uchar)'\367',
-(uchar)'\370',(uchar)'\371',(uchar)'\372',(uchar)'\373',(uchar)'\374',(uchar)'\375',(uchar)'\376',(uchar)'\377',
-};
-
-uchar NEAR sort_order_koi8_ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-' ', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar)'\245',(uchar)'\246',(uchar)'\247',(uchar)'\250',(uchar)'\251',(uchar)'\252',(uchar)'\253',(uchar)'\254',
-(uchar)'\255',(uchar)'\256',(uchar)'\257',(uchar)'\260',(uchar)'\261',(uchar)'\262',(uchar)'\263',(uchar)'\264',
-(uchar)'\265',(uchar)'\266',(uchar)'\267',(uchar)'\270',(uchar)'\271',(uchar)'\272',(uchar)'\273',(uchar)'\274',
-(uchar)'\275',(uchar)'\276',(uchar)'\277',(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',
-(uchar)'\305',(uchar)'\306',(uchar)'\307',(uchar)'\210',(uchar)'\207',(uchar)'\310',(uchar)'\214',(uchar)'\215',
-(uchar)'\311',(uchar)'\312',(uchar)'\313',(uchar)'\314',(uchar)'\315',(uchar)'\204',(uchar)'\316',(uchar)'\317',
-(uchar)'\320',(uchar)'\321',(uchar)'\322',(uchar)'\210',(uchar)'\207',(uchar)'\323',(uchar)'\214',(uchar)'\215',
-(uchar)'\324',(uchar)'\325',(uchar)'\326',(uchar)'\327',(uchar)'\330',(uchar)'\204',(uchar)'\331',(uchar)'\332',
-(uchar)'\243',(uchar)'\200',(uchar)'\201',(uchar)'\233',(uchar)'\205',(uchar)'\206',(uchar)'\231',(uchar)'\203',
-(uchar)'\232',(uchar)'\213',(uchar)'\216',(uchar)'\217',(uchar)'\220',(uchar)'\221',(uchar)'\222',(uchar)'\223',
-(uchar)'\224',(uchar)'\244',(uchar)'\225',(uchar)'\226',(uchar)'\227',(uchar)'\230',(uchar)'\211',(uchar)'\202',
-(uchar)'\241',(uchar)'\240',(uchar)'\212',(uchar)'\235',(uchar)'\242',(uchar)'\236',(uchar)'\234',(uchar)'\237',
-(uchar)'\243',(uchar)'\200',(uchar)'\201',(uchar)'\233',(uchar)'\205',(uchar)'\206',(uchar)'\231',(uchar)'\203',
-(uchar)'\232',(uchar)'\213',(uchar)'\216',(uchar)'\217',(uchar)'\220',(uchar)'\221',(uchar)'\222',(uchar)'\223',
-(uchar)'\224',(uchar)'\244',(uchar)'\225',(uchar)'\226',(uchar)'\227',(uchar)'\230',(uchar)'\211',(uchar)'\202',
-(uchar)'\241',(uchar)'\240',(uchar)'\212',(uchar)'\235',(uchar)'\242',(uchar)'\236',(uchar)'\234',(uchar)'\237',
-};
diff --git a/strings/Attic/ctype-latin1.c b/strings/Attic/ctype-latin1.c
deleted file mode 100644
index 470b72ce34e..00000000000
--- a/strings/Attic/ctype-latin1.c
+++ /dev/null
@@ -1,142 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* This implements the ISO 8859 Latin1 character-set */
-
-#include <global.h>
-#include "m_string.h"
-
-#if MY_CHARSET_CURRENT == MY_CHARSET_LATIN1
-
-uchar NEAR ctype_latin1[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,16,1,1,1,1,1,1,1,2,
-2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,16,2,2,2,2,2,2,2,2,
-};
-
-uchar NEAR to_lower_latin1[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\327',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\337',
-(uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
-(uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
-(uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
-(uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_latin1[]={
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
-(uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
-(uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
-(uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\367',
-(uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\377',
-};
-
-#ifndef __WIN32__
-uchar NEAR sort_order_latin1[]={
-#else
-uchar sort_order_latin1[]={
-#endif
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
-(uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
-(uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
-(uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
-(uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
-(uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
-(uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
-(uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
-'A', 'A', 'A', 'A', '\\', '[', '\\', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', ']', (uchar) '\327',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\337',
-'A', 'A', 'A', 'A', '\\', '[', '\\', 'C',
-'E', 'E', 'E', 'E', 'I', 'I', 'I', 'I',
-'D', 'N', 'O', 'O', 'O', 'O', ']', (uchar) '\367',
-(uchar) '\330','U', 'U', 'U', 'Y', 'Y', (uchar) '\336',(uchar) '\377',
-};
-#endif /* MY_CHARSET_LATIN1 */
diff --git a/strings/Attic/ctype-latin2.c b/strings/Attic/ctype-latin2.c
deleted file mode 100644
index 32ab6cface5..00000000000
--- a/strings/Attic/ctype-latin2.c
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * File generated by cset
- * (C) Abandoned 1997 Zarko Mocnik <zarko.mocnik@dem.si>
- *
- * August, 1997
- * Regenerated, Jaroslaw Lewandowski <jotel@itnet.com.pl>
- * - changed sort order characters with the accents :
- * a-ogonek, c-ogonek, e-ogonek, l-slash, n-acute, o-acute,
- * s-acute, z-acute, z-dot according to Polish alphabet standard.
- * - changed type for character 'diaeresis' to _P
- * Characters table are useful for Slovenian and Polish language
- * and ISO-8859-2 character set
- */
-
-#include <global.h>
-#include "m_string.h"
-
-#ifndef OLD_LATIN2_DEFINITION
-
-uchar NEAR ctype_latin2[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 72, 1, 16, 1, 16, 1, 1, 16, 16, 1, 1, 1, 1, 16, 1, 1,
- 16, 2, 16, 2, 16, 2, 2, 16, 16, 2, 2, 2, 2, 16, 2, 2,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 16, 1, 1, 1, 1, 1, 1, 16, 1, 1, 1, 1, 1, 1, 1, 16,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16, 2, 2, 2, 2, 2, 2, 2, 16,
-};
-
-uchar NEAR to_lower_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,177,162,179,164,181,182,167,168,185,186,187,188,173,190,191,
-176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-208,241,242,243,244,245,246,215,248,249,250,251,252,253,254,223,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,
-};
-
-uchar NEAR to_upper_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
-176,161,178,163,180,165,166,183,184,169,170,171,172,189,174,175,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-240,209,210,211,212,213,214,247,216,217,218,219,220,221,222,255,
-};
-
-uchar NEAR sort_order_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 68, 69, 72, 73, 75, 76, 77, 78, 79, 80, 81, 83, 84, 86,
- 88, 89, 90, 91, 94, 95, 96, 97, 98, 99,100,104,105,106,107,108,
-109, 65, 68, 69, 72, 73, 75, 76, 77, 78, 79, 80, 81, 83, 84, 86,
- 88, 89, 90, 91, 94, 95, 96, 97, 98, 99,100,110,111,112,113,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,
-255, 66,255, 82,255, 81, 92,255,255, 93, 91, 94,101,255,103,102,
-255, 66,255, 82,255, 81, 92,255,255, 93, 91, 94,101,255,103,102,
- 90, 67, 67, 67, 67, 81, 70, 69, 71, 73, 74, 73, 73, 78, 78, 72,
-255, 85, 84, 87, 86, 86, 86,255, 90, 95, 95, 95, 95, 99, 94,255,
- 90, 67, 67, 67, 67, 81, 70, 69, 71, 73, 74, 73, 73, 78, 78, 72,
-255, 85, 84, 87, 86, 86, 86,255, 90, 95, 95, 95, 95, 99, 94,255,
-};
-
-
-#else
-
-/*
- * File generated by cset
- * (C) Abandoned 1997 Zarko Mocnik <zarko.mocnik@dem.si>
- *
- * definition table reworked by Jaromir Dolecek <dolecek@ics.muni.cz>
- */
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_latin2[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132,132,132, 16, 16, 16, 16, 16, 16,
- 16,129,129,129,129,129,129, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
- 16,130,130,130,130,130,130, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 72,
- 1, 16, 1, 16, 1, 1, 16, 0, 0, 1, 1, 1, 1, 16, 1, 1,
- 16, 2, 16, 2, 16, 2, 2, 16, 16, 2, 2, 2, 2, 16, 2, 2,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 16, 1, 1, 1, 1, 1, 1, 16, 1, 1, 1, 1, 1, 1, 1, 16,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16, 2, 2, 2, 2, 2, 2, 2, 16,
-};
-
-uchar NEAR to_lower_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99,100,101,102,103,104,105,106,107,108,109,110,111,
-112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-177,161,179,163,181,182,166,167,168,185,186,187,188,173,190,191,
-176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-208,241,242,243,244,245,246,215,248,249,250,251,252,253,254,223,
-224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,
-240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,
-};
-
-uchar NEAR to_upper_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90,123,124,125,126,127,
-128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,
-144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,
-160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,
-176,160,178,162,180,164,165,183,184,169,170,171,172,189,174,175,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,
-192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,
-240,209,210,211,212,213,214,247,216,217,218,219,220,221,222,255,
-};
-
-uchar NEAR sort_order_latin2[] = {
- 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 71, 72, 76, 78, 83, 84, 85, 86, 90, 91, 92, 96, 97,100,
-105,106,107,110,114,117,122,123,124,125,127,131,132,133,134,135,
-136, 65, 71, 72, 76, 78, 83, 84, 85, 86, 90, 91, 92, 96, 97,100,
-105,106,107,110,114,117,122,123,124,125,127,137,138,139,140, 0,
- 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,255,
- 66,255, 93,255, 94,111,255,255,255,112,113,115,128,255,129,130,
-255, 66,255, 93,255, 94,111,255,255,112,113,115,128,255,129,130,
-108, 67, 68, 69, 70, 95, 73, 75, 74, 79, 81, 82, 80, 89, 87, 77,
-255, 98, 99,101,102,103,104,255,109,119,118,120,121,126,116,255,
-108, 67, 68, 69, 70, 95, 73, 75, 74, 79, 81, 82, 80, 89, 88, 77,
-255, 98, 99,101,102,103,104,255,109,119,118,120,121,126,116,255,
-};
-
-#endif
diff --git a/strings/Attic/ctype-swe7.c b/strings/Attic/ctype-swe7.c
deleted file mode 100644
index 19a79ecd3f7..00000000000
--- a/strings/Attic/ctype-swe7.c
+++ /dev/null
@@ -1,137 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-/* Define arrays to map character codes to types, uppercase,
- lowercase and sortorder. */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_swe7[257] =
-{
- 0, /* For standard library */
- 32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
- 32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
- 72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
- 1,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
- 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,16,
- 1,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
- 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,32,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-};
-
-uchar NEAR to_lower_swe7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '{', '|', '}', '~', '_',
- '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '{', '|', '}', '~', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_swe7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '[', '\\', ']', '^', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR sort_order_swe7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- 'E', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '\\', ']', '[', 'Y', '_',
- 'E', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '\\', ']', '[', 'Y', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-usa7.c b/strings/Attic/ctype-usa7.c
deleted file mode 100644
index 87e9d30f854..00000000000
--- a/strings/Attic/ctype-usa7.c
+++ /dev/null
@@ -1,134 +0,0 @@
-/* Copyright Abandoned 1996 TCX DataKonsult AB & Monty Program KB & Detron HB
- This file is public domain and comes with NO WARRANTY of any kind */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_usa7[257] =
-{
- 0, /* For standard library */
- 32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
- 32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
- 72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
- 132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
- 16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
- 1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
- 16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
- 2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-};
-
-uchar NEAR to_lower_usa7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '[', '\\', ']', '^', '_',
- '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
- 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
- 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
- 'x', 'y', 'z', '{', '|', '}', '~', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR to_upper_usa7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
- '`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
-
-uchar NEAR sort_order_usa7[]=
-{
- '\000','\001','\002','\003','\004','\005','\006','\007',
- '\010','\011','\012','\013','\014','\015','\016','\017',
- '\020','\021','\022','\023','\024','\025','\026','\027',
- '\030','\031','\032','\033','\034','\035','\036','\037',
- ' ', '!', '"', '#', '$', '%', '&', '\'',
- '(', ')', '*', '+', ',', '-', '.', '/',
- '0', '1', '2', '3', '4', '5', '6', '7',
- '8', '9', ':', ';', '<', '=', '>', '?',
- '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '\\', ']', '[', '^', '_',
- 'E', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
- 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
- 'X', 'Y', 'Z', '{', '|', '}', 'Y', '\177',
- (uchar) '\200',(uchar) '\201',(uchar) '\202',(uchar) '\203',(uchar) '\204',(uchar) '\205',(uchar) '\206',(uchar) '\207',
- (uchar) '\210',(uchar) '\211',(uchar) '\212',(uchar) '\213',(uchar) '\214',(uchar) '\215',(uchar) '\216',(uchar) '\217',
- (uchar) '\220',(uchar) '\221',(uchar) '\222',(uchar) '\223',(uchar) '\224',(uchar) '\225',(uchar) '\226',(uchar) '\227',
- (uchar) '\230',(uchar) '\231',(uchar) '\232',(uchar) '\233',(uchar) '\234',(uchar) '\235',(uchar) '\236',(uchar) '\237',
- (uchar) '\240',(uchar) '\241',(uchar) '\242',(uchar) '\243',(uchar) '\244',(uchar) '\245',(uchar) '\246',(uchar) '\247',
- (uchar) '\250',(uchar) '\251',(uchar) '\252',(uchar) '\253',(uchar) '\254',(uchar) '\255',(uchar) '\256',(uchar) '\257',
- (uchar) '\260',(uchar) '\261',(uchar) '\262',(uchar) '\263',(uchar) '\264',(uchar) '\265',(uchar) '\266',(uchar) '\267',
- (uchar) '\270',(uchar) '\271',(uchar) '\272',(uchar) '\273',(uchar) '\274',(uchar) '\275',(uchar) '\276',(uchar) '\277',
- (uchar) '\300',(uchar) '\301',(uchar) '\302',(uchar) '\303',(uchar) '\304',(uchar) '\305',(uchar) '\306',(uchar) '\307',
- (uchar) '\310',(uchar) '\311',(uchar) '\312',(uchar) '\313',(uchar) '\314',(uchar) '\315',(uchar) '\316',(uchar) '\317',
- (uchar) '\320',(uchar) '\321',(uchar) '\322',(uchar) '\323',(uchar) '\324',(uchar) '\325',(uchar) '\326',(uchar) '\327',
- (uchar) '\330',(uchar) '\331',(uchar) '\332',(uchar) '\333',(uchar) '\334',(uchar) '\335',(uchar) '\336',(uchar) '\337',
- (uchar) '\340',(uchar) '\341',(uchar) '\342',(uchar) '\343',(uchar) '\344',(uchar) '\345',(uchar) '\346',(uchar) '\347',
- (uchar) '\350',(uchar) '\351',(uchar) '\352',(uchar) '\353',(uchar) '\354',(uchar) '\355',(uchar) '\356',(uchar) '\357',
- (uchar) '\360',(uchar) '\361',(uchar) '\362',(uchar) '\363',(uchar) '\364',(uchar) '\365',(uchar) '\366',(uchar) '\367',
- (uchar) '\370',(uchar) '\371',(uchar) '\372',(uchar) '\373',(uchar) '\374',(uchar) '\375',(uchar) '\376',(uchar) '\377',
-};
diff --git a/strings/Attic/ctype-win1250.c b/strings/Attic/ctype-win1250.c
deleted file mode 100644
index 300f6967ac4..00000000000
--- a/strings/Attic/ctype-win1250.c
+++ /dev/null
@@ -1,152 +0,0 @@
-/* ctype-win1250.c */
-/*
- * win1250 code page with Croatian sort order
- * Created by Davor Stare, Zagreb, 1999.
- * This file is public domain and comes with NO WARRANTY of any kind.
- * Send comments to: davor.stare@artronic.hr
- */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_win1250[257] = {
-0,
- 32, 32, 32, 32, 32, 32, 32, 32,
- 32, 40, 40, 40, 40, 40, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32,
- 32, 32, 32, 32, 32, 32, 32, 32,
- 72, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16,
-132, 132, 132, 132, 132, 132, 132, 132,
-132, 132, 16, 16, 16, 16, 16, 16,
- 16, 129, 129, 129, 129, 129, 129, 1,
- 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 16, 16, 16, 16, 16,
- 16, 130, 130, 130, 130, 130, 130, 2,
- 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 16, 16, 16, 16, 32,
- 32, 32, 16, 32, 16, 16, 16, 16,
- 32, 16, 1, 16, 1, 1, 1, 1,
- 32, 16, 16, 16, 16, 16, 16, 16,
- 32, 16, 2, 16, 2, 2, 2, 2,
- 72, 16, 16, 1, 16, 1, 16, 1,
- 16, 16, 1, 16, 16, 16, 16, 1,
- 16, 16, 16, 2, 16, 16, 16, 16,
- 16, 2, 2, 16, 1, 16, 2, 2,
- 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 16,
- 1, 1, 1, 1, 1, 1, 1, 2,
- 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 16,
- 2, 2, 2, 2, 2, 2, 2, 16
-};
-
-uchar NEAR to_lower_win1250[]={
- 0, 1, 2, 3, 4, 5, 6, 7,
- 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55,
- 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 97, 98, 99, 100, 101, 102, 103,
-104, 105, 106, 107, 108, 109, 110, 111,
-112, 113, 114, 115, 116, 117, 118, 119,
-120, 121, 122, 91, 92, 93, 94, 95,
- 96, 97, 98, 99, 100, 101, 102, 103,
-104, 105, 106, 107, 108, 109, 110, 111,
-112, 113, 114, 115, 116, 117, 118, 119,
-120, 121, 122, 123, 124, 125, 126, 127,
-128, 129, 130, 131, 132, 133, 134, 135,
-136, 137, 154, 139, 156, 157, 158, 159,
-144, 145, 146, 147, 148, 149, 150, 151,
-152, 153, 154, 155, 156, 157, 158, 159,
-160, 161, 162, 179, 164, 185, 166, 223,
-168, 169, 186, 171, 172, 173, 174, 191,
-176, 177, 178, 179, 180, 181, 182, 183,
-184, 185, 186, 187, 190, 189, 190, 191,
-224, 225, 226, 227, 228, 229, 230, 231,
-232, 233, 234, 235, 236, 237, 238, 239,
-240, 241, 242, 243, 244, 245, 246, 215,
-248, 249, 250, 251, 252, 253, 254, 223,
-224, 225, 226, 227, 228, 229, 230, 231,
-232, 233, 234, 235, 236, 237, 238, 239,
-240, 241, 242, 243, 244, 245, 246, 247,
-248, 249, 250, 251, 252, 253, 254, 255
-};
-
-uchar NEAR to_upper_win1250[]={
- 0, 1, 2, 3, 4, 5, 6, 7,
- 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55,
- 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87,
- 88, 89, 90, 91, 92, 93, 94, 95,
- 96, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 74, 75, 76, 77, 78, 79,
- 80, 81, 82, 83, 84, 85, 86, 87,
- 88, 89, 90, 123, 124, 125, 126, 127,
-128, 129, 130, 131, 132, 133, 134, 135,
-136, 137, 138, 139, 140, 141, 142, 143,
-144, 145, 146, 147, 148, 149, 150, 151,
-152, 153, 138, 155, 140, 141, 142, 143,
-160, 161, 162, 163, 164, 165, 166, 167,
-168, 169, 170, 171, 172, 173, 174, 175,
-176, 177, 178, 163, 180, 181, 182, 183,
-184, 165, 170, 187, 188, 189, 188, 175,
-192, 193, 194, 195, 196, 197, 198, 199,
-200, 201, 202, 203, 204, 205, 206, 207,
-208, 209, 210, 211, 212, 213, 214, 215,
-216, 217, 218, 219, 220, 221, 222, 167,
-192, 193, 194, 195, 196, 197, 198, 199,
-200, 201, 202, 203, 204, 205, 206, 207,
-208, 209, 210, 211, 212, 213, 214, 247,
-216, 217, 218, 219, 220, 221, 222, 255
-};
-
-uchar NEAR sort_order_win1250[]={
- 0, 1, 2, 3, 4, 5, 6, 7,
- 8, 9, 10, 11, 12, 13, 14, 15,
- 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 53, 54, 55,
- 56, 57, 58, 59, 60, 61, 62, 63,
- 64, 65, 66, 67, 70, 73, 74, 75,
- 76, 77, 78, 79, 80, 82, 83, 85,
- 86, 87, 88, 89, 91, 92, 93, 94,
- 95, 96, 97, 99, 100, 101, 102, 103,
-104, 65, 66, 67, 70, 73, 74, 75,
- 76, 77, 78, 79, 80, 82, 83, 85,
- 86, 87, 88, 89, 91, 92, 93, 94,
- 95, 96, 97, 123, 124, 125, 126, 127,
-128, 129, 130, 131, 132, 133, 134, 135,
-136, 137, 90, 139, 90, 91, 98, 98,
-144, 145, 146, 147, 148, 149, 150, 151,
-152, 153, 90, 155, 90, 91, 98, 98,
- 32, 161, 162, 80, 164, 65, 166, 89,
-168, 169, 89, 171, 172, 173, 174, 98,
-176, 177, 178, 80, 180, 181, 182, 183,
-184, 65, 89, 187, 80, 189, 80, 98,
- 88, 65, 65, 65, 65, 80, 69, 67,
- 68, 73, 73, 73, 73, 77, 77, 70,
- 71, 83, 83, 85, 85, 85, 85, 215,
- 88, 92, 92, 92, 92, 96, 91, 89,
- 88, 65, 65, 65, 65, 80, 69, 67,
- 68, 73, 73, 73, 73, 77, 77, 70,
- 71, 83, 83, 85, 85, 85, 85, 247,
- 88, 92, 92, 92, 92, 96, 91, 255
-};
-
diff --git a/strings/Attic/ctype-win1251.c b/strings/Attic/ctype-win1251.c
deleted file mode 100644
index fadad184dad..00000000000
--- a/strings/Attic/ctype-win1251.c
+++ /dev/null
@@ -1,135 +0,0 @@
-/* ctype-win1251.c */
-/*
- * Created by Rustam B. Abdullaev, Tashkent, 1998.
- * This file is public domain and comes with NO WARRANTY of any kind.
- * Send bugs and wishes to: rustik@writeme.com
- */
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_win1251[257] = {
-0,
-32, 32, 32, 32, 32, 32, 32, 32, 32, 40, 40, 40, 40, 40, 32, 32,
-32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
-72, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-132,132,132,132,132,132,132,132, 132,132,16, 16, 16, 16, 16, 16,
-16, 129,129,129,129,129,129,1, 1, 1, 1, 1, 1, 1, 1, 1,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 16, 16,
-16, 130,130,130,130,130,130,2, 2, 2, 2, 2, 2, 2, 2, 2,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, 16, 16, 16, 32,
-16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
-16, 16, 16, 16, 16, 16, 16, 16, 1, 16, 16, 16, 16, 16, 16, 16,
-16, 16, 16, 16, 16, 16, 16, 16, 2, 16, 16, 16, 16, 16, 16, 16,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
-};
-
-uchar NEAR to_lower_win1251[]={
-'\0', '\x1', '\x2', '\x3', '\x4', '\x5', '\x6', '\x7',
-'\x8', '\x9', '\xA', '\xB', '\xC', '\xD', '\xE', '\xF',
-'\x10','\x11','\x12','\x13','\x14','\x15','\x16','\x17',
-'\x18','\x19','\x1A','\x1B','\x1C','\x1D','\x1E','\x1F',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-'`', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\x7F',
-'\x80','\x81','\x82','\x83','\x84','\x85','\x86','\x87',
-'\x88','\x89','\x8A','\x8B','\x8C','\x8D','\x8E','\x8F',
-'\x90','\x91','\x92','\x93','\x94','\x95','\x96','\x97',
-'\x98','\x99','\x9A','\x9B','\x9C','\x9D','\x9E','\x9F',
-'\xA0','\xA1','\xA2','\xA3','\xA4','\xA5','\xA6','\xA7',
-'\xB8','\xA9','\xAA','\xAB','\xAC','\xAD','\xAE','\xAF',
-'\xB0','\xB1','\xB2','\xB3','\xB4','\xB5','\xB6','\xB7',
-'\xB8','\xB9','\xBA','\xBB','\xBC','\xBD','\xBE','\xBF',
-'\xE0','\xE1','\xE2','\xE3','\xE4','\xE5','\xE6','\xE7',
-'\xE8','\xE9','\xEA','\xEB','\xEC','\xED','\xEE','\xEF',
-'\xF0','\xF1','\xF2','\xF3','\xF4','\xF5','\xF5','\xF7',
-'\xF8','\xF9','\xFA','\xFB','\xFC','\xFD','\xFE','\xFF',
-'\xE0','\xE1','\xE2','\xE3','\xE4','\xE5','\xE6','\xE7',
-'\xE8','\xE9','\xEA','\xEB','\xEC','\xED','\xEE','\xEF',
-'\xF0','\xF1','\xF2','\xF3','\xF4','\xF5','\xF6','\xF7',
-'\xF8','\xF9','\xFA','\xFB','\xFC','\xFD','\xFE','\xFF'
-};
-
-uchar NEAR to_upper_win1251[]={
-'\0', '\x1', '\x2', '\x3', '\x4', '\x5', '\x6', '\x7',
-'\x8', '\x9', '\xA', '\xB', '\xC', '\xD', '\xE', '\xF',
-'\x10','\x11','\x12','\x13','\x14','\x15','\x16','\x17',
-'\x18','\x19','\x1A','\x1B','\x1C','\x1D','\x1E','\x1F',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\x7F',
-'\x80','\x81','\x82','\x83','\x84','\x85','\x86','\x87',
-'\x88','\x89','\x8A','\x8B','\x8C','\x8D','\x8E','\x8F',
-'\x90','\x91','\x92','\x93','\x94','\x95','\x96','\x97',
-'\x98','\x99','\x9A','\x9B','\x9C','\x9D','\x9E','\x9F',
-'\xA0','\xA1','\xA2','\xA3','\xA4','\xA5','\xA6','\xA7',
-'\xA8','\xA9','\xAA','\xAB','\xAC','\xAD','\xAE','\xAF',
-'\xB0','\xB1','\xB2','\xB3','\xB4','\xB5','\xB6','\xB7',
-'\xA8','\xB9','\xBA','\xBB','\xBC','\xBD','\xBE','\xBF',
-'\xC0','\xC1','\xC2','\xC3','\xC4','\xC5','\xC6','\xC7',
-'\xC8','\xC9','\xCA','\xCB','\xCC','\xCD','\xCE','\xCF',
-'\xD0','\xD1','\xD2','\xD3','\xD4','\xD5','\xD5','\xD7',
-'\xD8','\xD9','\xDA','\xDB','\xDC','\xDD','\xDE','\xDF',
-'\xC0','\xC1','\xC2','\xC3','\xC4','\xC5','\xC6','\xC7',
-'\xC8','\xC9','\xCA','\xCB','\xCC','\xCD','\xCE','\xCF',
-'\xD0','\xD1','\xD2','\xD3','\xD4','\xD5','\xD6','\xD7',
-'\xD8','\xD9','\xDA','\xDB','\xDC','\xDD','\xDE','\xDF'
-};
-
-uchar NEAR sort_order_win1251[]={
-'\0', '\x1', '\x2', '\x3', '\x4', '\x5', '\x6', '\x7',
-'\x8', '\x9', '\xA', '\xB', '\xC', '\xD', '\xE', '\xF',
-'\x10','\x11','\x12','\x13','\x14','\x15','\x16','\x17',
-'\x18','\x19','\x1A','\x1B','\x1C','\x1D','\x1E','\x1F',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-'`', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\x7F',
-'\x80','\x81','\x82','\x83','\x84','\x85','\x86','\x87',
-'\x88','\x89','\x8A','\x8B','\x8C','\x8D','\x8E','\x8F',
-'\x90','\x91','\x92','\x93','\x94','\x95','\x96','\x97',
-'\x98','\x99','\x9A','\x9B','\x9C','\x9D','\x9E','\x9F',
-'\xA0','\xA1','\xA2','\xA3','\xA4','\xA5','\xA6','\xA7',
-'\xC6','\xA9','\xAA','\xAB','\xAC','\xAD','\xAE','\xAF',
-'\xB0','\xB1','\xB2','\xB3','\xB4','\xB5','\xB6','\xB7',
-'\xC6','\xB9','\xBA','\xBB','\xBC','\xBD','\xBE','\xBF',
-'\xC0','\xC1','\xC2','\xC3','\xC4','\xC5','\xC7','\xC8',
-'\xC9','\xCA','\xCB','\xCC','\xCD','\xCE','\xCF','\xD0',
-'\xD1','\xD2','\xD3','\xD4','\xD5','\xD6','\xD7','\xD8',
-'\xD9','\xDA','\xDB','\xDC','\xDD','\xDE','\xDF','\xE0',
-'\xC0','\xC1','\xC2','\xC3','\xC4','\xC5','\xC7','\xC8',
-'\xC9','\xCA','\xCB','\xCC','\xCD','\xCE','\xCF','\xD0',
-'\xD1','\xD2','\xD3','\xD4','\xD5','\xD6','\xD7','\xD8',
-'\xD9','\xDA','\xDB','\xDC','\xDD','\xDE','\xDF','\xE0'
-};
-
diff --git a/strings/Attic/ctype-win1251ukr.c b/strings/Attic/ctype-win1251ukr.c
deleted file mode 100644
index ae33e04f38f..00000000000
--- a/strings/Attic/ctype-win1251ukr.c
+++ /dev/null
@@ -1,142 +0,0 @@
-//Created by Max Veremayenko (verem@tg.kiev.ua)
-//As standart for ukranian font i use ukrainian for window95
-
-#include <global.h>
-#include "m_string.h"
-
-uchar NEAR ctype_win1251ukr[257] = {
-0,
-32,32,32,32,32,32,32,32,32,40,40,40,40,40,32,32,
-32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,
-72,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,
-132,132,132,132,132,132,132,132,132,132,16,16,16,16,16,16,
-16,129,129,129,129,129,129,1,1,1,1,1,1,1,1,1,
-1,1,1,1,1,1,1,1,1,1,1,16,16,16,16,16,
-16,130,130,130,130,130,130,2,2,2,2,2,2,2,2,2,
-2,2,2,2,2,2,2,2,2,2,2,16,16,16,16,32,
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\1',(uchar)'\20',(uchar)'\20',
-(uchar)'\1',(uchar)'\20',(uchar)'\1',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\1',
-(uchar)'\20',(uchar)'\20',(uchar)'\1',(uchar)'\2',(uchar)'\2',(uchar)'\20',(uchar)'\20',(uchar)'\20',
-(uchar)'\2',(uchar)'\20',(uchar)'\2',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\20',(uchar)'\2',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',(uchar)'\1',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',(uchar)'\2',
-};
-
-uchar NEAR to_lower_win1251ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '[', '\\', ']', '^', '_',
-' ', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
-'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
-'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
-'x', 'y', 'z', '{', '|', '}', '~', '\177',
-
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\245',(uchar)'\40',(uchar)'\40',
-(uchar)'\250',(uchar)'\40',(uchar)'\252',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\257',
-(uchar)'\40',(uchar)'\40',(uchar)'\262',(uchar)'\262',(uchar)'\245',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\250',(uchar)'\40',(uchar)'\252',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\257',
-(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',(uchar)'\305',(uchar)'\306',(uchar)'\307',
-(uchar)'\310',(uchar)'\311',(uchar)'\312',(uchar)'\313',(uchar)'\314',(uchar)'\315',(uchar)'\316',(uchar)'\317',
-(uchar)'\320',(uchar)'\321',(uchar)'\322',(uchar)'\323',(uchar)'\324',(uchar)'\325',(uchar)'\326',(uchar)'\327',
-(uchar)'\330',(uchar)'\331',(uchar)'\332',(uchar)'\333',(uchar)'\334',(uchar)'\335',(uchar)'\336',(uchar)'\337',
-(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',(uchar)'\305',(uchar)'\306',(uchar)'\307',
-(uchar)'\310',(uchar)'\311',(uchar)'\312',(uchar)'\313',(uchar)'\314',(uchar)'\315',(uchar)'\316',(uchar)'\317',
-(uchar)'\320',(uchar)'\321',(uchar)'\322',(uchar)'\323',(uchar)'\324',(uchar)'\325',(uchar)'\326',(uchar)'\327',
-(uchar)'\330',(uchar)'\331',(uchar)'\332',(uchar)'\333',(uchar)'\334',(uchar)'\335',(uchar)'\336',(uchar)'\337',
-};
-
-uchar NEAR to_upper_win1251ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-' ', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\264',(uchar)'\40',(uchar)'\40',
-(uchar)'\270',(uchar)'\40',(uchar)'\272',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\277',
-(uchar)'\40',(uchar)'\40',(uchar)'\263',(uchar)'\263',(uchar)'\264',(uchar)'\40',(uchar)'\40',(uchar)'\40',
-(uchar)'\270',(uchar)'\40',(uchar)'\272',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\40',(uchar)'\277',
-(uchar)'\340',(uchar)'\341',(uchar)'\342',(uchar)'\343',(uchar)'\344',(uchar)'\345',(uchar)'\346',(uchar)'\347',
-(uchar)'\350',(uchar)'\351',(uchar)'\352',(uchar)'\353',(uchar)'\354',(uchar)'\355',(uchar)'\356',(uchar)'\357',
-(uchar)'\360',(uchar)'\361',(uchar)'\362',(uchar)'\363',(uchar)'\364',(uchar)'\365',(uchar)'\366',(uchar)'\367',
-(uchar)'\370',(uchar)'\371',(uchar)'\372',(uchar)'\373',(uchar)'\374',(uchar)'\375',(uchar)'\376',(uchar)'\377',
-(uchar)'\340',(uchar)'\341',(uchar)'\342',(uchar)'\343',(uchar)'\344',(uchar)'\345',(uchar)'\346',(uchar)'\347',
-(uchar)'\350',(uchar)'\351',(uchar)'\352',(uchar)'\353',(uchar)'\354',(uchar)'\355',(uchar)'\356',(uchar)'\357',
-(uchar)'\360',(uchar)'\361',(uchar)'\362',(uchar)'\363',(uchar)'\364',(uchar)'\365',(uchar)'\366',(uchar)'\367',
-(uchar)'\370',(uchar)'\371',(uchar)'\372',(uchar)'\373',(uchar)'\374',(uchar)'\375',(uchar)'\376',(uchar)'\377',
-};
-
-uchar NEAR sort_order_win1251ukr[] = {
-'\000','\001','\002','\003','\004','\005','\006','\007',
-'\010','\011','\012','\013','\014','\015','\016','\017',
-'\020','\021','\022','\023','\024','\025','\026','\027',
-'\030','\031','\032','\033','\034','\035','\036','\037',
-' ', '!', '"', '#', '$', '%', '&', '\'',
-'(', ')', '*', '+', ',', '-', '.', '/',
-'0', '1', '2', '3', '4', '5', '6', '7',
-'8', '9', ':', ';', '<', '=', '>', '?',
-'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '[', '\\', ']', '^', '_',
-' ', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
-'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
-'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W',
-'X', 'Y', 'Z', '{', '|', '}', '~', '\177',
-
-(uchar)'\245',(uchar)'\246',(uchar)'\247',(uchar)'\250',(uchar)'\251',(uchar)'\252',(uchar)'\253',(uchar)'\254',
-(uchar)'\255',(uchar)'\256',(uchar)'\257',(uchar)'\260',(uchar)'\261',(uchar)'\262',(uchar)'\263',(uchar)'\264',
-(uchar)'\265',(uchar)'\266',(uchar)'\267',(uchar)'\270',(uchar)'\271',(uchar)'\272',(uchar)'\273',(uchar)'\274',
-(uchar)'\275',(uchar)'\276',(uchar)'\277',(uchar)'\300',(uchar)'\301',(uchar)'\302',(uchar)'\303',(uchar)'\304',
-(uchar)'\305',(uchar)'\306',(uchar)'\307',(uchar)'\310',(uchar)'\311',(uchar)'\204',(uchar)'\312',(uchar)'\313',
-(uchar)'\210',(uchar)'\314',(uchar)'\207',(uchar)'\315',(uchar)'\316',(uchar)'\317',(uchar)'\320',(uchar)'\215',
-(uchar)'\321',(uchar)'\322',(uchar)'\214',(uchar)'\214',(uchar)'\204',(uchar)'\323',(uchar)'\324',(uchar)'\325',
-(uchar)'\210',(uchar)'\326',(uchar)'\207',(uchar)'\327',(uchar)'\330',(uchar)'\331',(uchar)'\332',(uchar)'\215',
-(uchar)'\200',(uchar)'\201',(uchar)'\202',(uchar)'\203',(uchar)'\205',(uchar)'\206',(uchar)'\211',(uchar)'\212',
-(uchar)'\213',(uchar)'\216',(uchar)'\217',(uchar)'\220',(uchar)'\221',(uchar)'\222',(uchar)'\223',(uchar)'\224',
-(uchar)'\225',(uchar)'\226',(uchar)'\227',(uchar)'\230',(uchar)'\231',(uchar)'\232',(uchar)'\233',(uchar)'\234',
-(uchar)'\235',(uchar)'\236',(uchar)'\237',(uchar)'\240',(uchar)'\241',(uchar)'\242',(uchar)'\243',(uchar)'\244',
-(uchar)'\200',(uchar)'\201',(uchar)'\202',(uchar)'\203',(uchar)'\205',(uchar)'\206',(uchar)'\211',(uchar)'\212',
-(uchar)'\213',(uchar)'\216',(uchar)'\217',(uchar)'\220',(uchar)'\221',(uchar)'\222',(uchar)'\223',(uchar)'\224',
-(uchar)'\225',(uchar)'\226',(uchar)'\227',(uchar)'\230',(uchar)'\231',(uchar)'\232',(uchar)'\233',(uchar)'\234',
-(uchar)'\235',(uchar)'\236',(uchar)'\237',(uchar)'\240',(uchar)'\241',(uchar)'\242',(uchar)'\243',(uchar)'\244',
-
-};
diff --git a/strings/Attic/ctype.c.in b/strings/Attic/ctype.c.in
deleted file mode 100644
index 2a76246a03a..00000000000
--- a/strings/Attic/ctype.c.in
+++ /dev/null
@@ -1,20 +0,0 @@
-#include <global.h>
-#include <m_ctype.h>
-
-@CHARSET_DECLARATIONS@
-
-static CHARSET_INFO comp_cs[] = {
-@CHARSET_COMP_CS_INIT@
-};
-
-CHARSET_INFO *default_charset_info = &comp_cs[0];
-
-CHARSET_INFO *find_compiled_charset(uint8 cs_number)
-{
- uint i;
- for (i = 0; i < array_elements(comp_cs); ++i)
- if (comp_cs[i].number == cs_number)
- return &comp_cs[i];
-
- return NULL;
-}
diff --git a/strings/Attic/memory.h b/strings/Attic/memory.h
deleted file mode 100644
index 9b959336caf..00000000000
--- a/strings/Attic/memory.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/* File : memory.h
- Author : Richard A. O'Keefe.
- Updated: 1 June 1984
- Purpose: Header file for the System V "memory(3C)" package.
-
- All the functions in this package are the original work of Richard
- A. O'Keefe. Any resemblance between them and any functions in AT&T
- or other licensed software is due entirely to my use of the System V
- memory(3C) manual page as a specification. See the READ-ME to find
- the conditions under which this material may be used and copied.
-
- The System V manual says that the mem* functions are declared in the
- <memory.h> file. This file is also included in the <strings.h> file,
- but it does no harm to #include both in either order.
-*/
-
-#ifndef DGUX
-#ifndef memeql
-
-#define memeql !memcmp
-extern int memcmp(/*char^,char^,int*/);
-#ifndef memcpy
-extern char *memcpy(/*char^,char^,int*/);
-#endif
-extern char *memccpy(/*char^,char^,char,int*/);
-extern char *memset(/*char^,char,int*/);
-extern char *memchr(/*char^,char,int*/);
-extern char *memrchr(/*char^,char,int*/);
-extern char *memmov(/*char^,char^,int*/);
-extern void memrev(/*char^,char^,int*/);
-
-#endif /* memeql */
-#endif
diff --git a/strings/Attic/ptr_cmp.c b/strings/Attic/ptr_cmp.c
deleted file mode 100644
index d3d4a36a054..00000000000
--- a/strings/Attic/ptr_cmp.c
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- get_ptr_compare(len) returns a pointer to a optimal byte-compare function
- for a array of stringpointer where all strings have size len.
- The bytes are compare as unsigned chars.
- Because the size is saved in a static variable.
- When using threads the program must have called my_init and the thread
- my_init_thread()
- */
-
-#include <global.h>
-#include "m_string.h"
-
-static int ptr_compare(uchar **a, uchar **b);
-static int ptr_compare_0(uchar **a, uchar **b);
-static int ptr_compare_1(uchar **a, uchar **b);
-static int ptr_compare_2(uchar **a, uchar **b);
-static int ptr_compare_3(uchar **a, uchar **b);
-
-#ifdef THREAD
-#include <my_pthread.h>
-#define compare_length my_thread_var->cmp_length
-#else
-static uint compare_length;
-#endif
-
- /* Get a pointer to a optimal byte-compare function for a given size */
-
-qsort_cmp get_ptr_compare (uint size)
-{
- compare_length=size; /* Remember for loop */
-
- if (size < 4)
- return (qsort_cmp) ptr_compare;
- switch (size & 3) {
- case 0: return (qsort_cmp) ptr_compare_0;
- case 1: return (qsort_cmp) ptr_compare_1;
- case 2: return (qsort_cmp) ptr_compare_2;
- case 3: return (qsort_cmp) ptr_compare_3;
- }
- return 0; /* Impossible */
-}
-
-
- /*
- Compare to keys to see witch is smaller.
- Loop unrolled to make it quick !!
- */
-
-#define cmp(N) if (first[N] != last[N]) return (int) first[N] - (int) last[N]
-
-static int ptr_compare(uchar **a, uchar **b)
-{
- reg3 int length= compare_length;
- reg1 uchar *first,*last;
-
- first= *a; last= *b;
- while (--length)
- {
- if (*first++ != *last++)
- return (int) first[-1] - (int) last[-1];
- }
- return (int) first[0] - (int) last[0];
-}
-
-
-static int ptr_compare_0(uchar **a, uchar **b)
-{
- reg3 int length= compare_length;
- reg1 uchar *first,*last;
-
- first= *a; last= *b;
- loop:
- cmp(0);
- cmp(1);
- cmp(2);
- cmp(3);
- if ((length-=4))
- {
- first+=4;
- last+=4;
- goto loop;
- }
- return (0);
-}
-
-
-static int ptr_compare_1(uchar **a, uchar **b)
-{
- reg3 int length= compare_length-1;
- reg1 uchar *first,*last;
-
- first= *a+1; last= *b+1;
- cmp(-1);
- loop:
- cmp(0);
- cmp(1);
- cmp(2);
- cmp(3);
- if ((length-=4))
- {
- first+=4;
- last+=4;
- goto loop;
- }
- return (0);
-}
-
-static int ptr_compare_2(uchar **a, uchar **b)
-{
- reg3 int length= compare_length-2;
- reg1 uchar *first,*last;
-
- first= *a +2 ; last= *b +2;
- cmp(-2);
- cmp(-1);
- loop:
- cmp(0);
- cmp(1);
- cmp(2);
- cmp(3);
- if ((length-=4))
- {
- first+=4;
- last+=4;
- goto loop;
- }
- return (0);
-}
-
-static int ptr_compare_3(uchar **a, uchar **b)
-{
- reg3 int length= compare_length-3;
- reg1 uchar *first,*last;
-
- first= *a +3 ; last= *b +3;
- cmp(-3);
- cmp(-2);
- cmp(-1);
- loop:
- cmp(0);
- cmp(1);
- cmp(2);
- cmp(3);
- if ((length-=4))
- {
- first+=4;
- last+=4;
- goto loop;
- }
- return (0);
-}
diff --git a/support-files/Attic/my-example.cnf.sh b/support-files/Attic/my-example.cnf.sh
deleted file mode 100644
index f91478a3037..00000000000
--- a/support-files/Attic/my-example.cnf.sh
+++ /dev/null
@@ -1,39 +0,0 @@
-# Example mysql config file.
-# You can copy this to one of:
-# @sysconfdir@/my.cnf to set global options,
-# mysql-data-dir/my.cnf to set server-specific options (in this
-# installation this directory is @localstatedir@) or
-# ~/.my.cnf to set user-specific options.
-#
-# One can use all long options that the program supports.
-# Run the program with --help to get a list of available options
-
-# This will be passed to all mysql clients
-[client]
-#password = my_password
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-
-# Here is entries for some specific programs
-# The following values assume you have at least 32M ram
-
-# The MySQL server
-[mysqld]
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-skip-locking
-set-variable = key_buffer=16M
-set-variable = max_allowed_packet=1M
-set-variable = thread_stack=128K
-# Start logging
-log
-
-[mysqldump]
-quick
-set-variable = max_allowed_packet=16M
-
-[mysql]
-no-auto-rehash
-
-[isamchk]
-set-variable = key_buffer=16M
diff --git a/support-files/Attic/my-huge.cfg.sh b/support-files/Attic/my-huge.cfg.sh
deleted file mode 100644
index 75faa1da276..00000000000
--- a/support-files/Attic/my-huge.cfg.sh
+++ /dev/null
@@ -1,60 +0,0 @@
-# Example mysql config file for very large systems.
-#
-# This is for large system with memory of 1G-2G where the system runs mainly
-# MySQL.
-#
-# You can copy this file to
-# /etc/mf.cnf to set global options,
-# mysql-data-dir/my.cnf to set server-specific options (in this
-# installation this directory is @localstatedir@) or
-# ~/.my.cnf to set user-specific options.
-#
-# One can in this file use all long options that the program supports.
-# If you want to know which options a program support, run the program
-# with --help option.
-
-# The following options will be passed to all MySQL clients
-[client]
-#password = your_password
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-
-# Here follows entries for some specific programs
-
-# The MySQL server
-[mysqld]
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-#tmpdir = /tmp/ # Put this on a dedicated disk
-skip-locking
-set-variable = key_buffer=512M
-set-variable = max_allowed_packet=1M
-set-variable = table_cache=512
-set-variable = sort_buffer=2M
-set-variable = record_buffer=2M
-set-variable = thread_cache=8
-set-variable = thread_concurrency=8 # Try number of CPU's*2
-set-variable = myisam_sort_buffer_size=64M
-#set-variable = bdb_cache_size=256M
-# Only log updates
-log-update
-
-[mysqldump]
-quick
-set-variable = max_allowed_packet=16M
-
-[mysql]
-no-auto-rehash
-#safe-updates # Remove the comment character if you are not familiar with SQL
-
-[isamchk]
-set-variable = key_buffer=256M
-set-variable = sort_buffer=256M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
-
-[myisamchk]
-set-variable = key_buffer=256M
-set-variable = sort_buffer=256M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
diff --git a/support-files/Attic/my-large.cfg.sh b/support-files/Attic/my-large.cfg.sh
deleted file mode 100644
index 01e830ae16c..00000000000
--- a/support-files/Attic/my-large.cfg.sh
+++ /dev/null
@@ -1,60 +0,0 @@
-# Example mysql config file for large systems.
-#
-# This is for large system with memory = 512M where the system runs mainly
-# MySQL.
-#
-# You can copy this file to
-# /etc/mf.cnf to set global options,
-# mysql-data-dir/my.cnf to set server-specific options (in this
-# installation this directory is @localstatedir@) or
-# ~/.my.cnf to set user-specific options.
-#
-# One can in this file use all long options that the program supports.
-# If you want to know which options a program support, run the program
-# with --help option.
-
-# The following options will be passed to all MySQL clients
-[client]
-#password = your_password
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-
-# Here follows entries for some specific programs
-
-# The MySQL server
-[mysqld]
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-#tmpdir = /tmp/ # Put this on a dedicated disk
-skip-locking
-set-variable = key_buffer=256M
-set-variable = max_allowed_packet=1M
-set-variable = table_cache=256
-set-variable = sort_buffer=1M
-set-variable = record_buffer=1M
-set-variable = myisam_sort_buffer_size=64M
-set-variable = thread_cache=8
-set-variable = thread_concurrency=8 # Try number of CPU's*2
-#set-variable = bdb_cache_size=64M
-# Only log updates
-log-update
-
-[mysqldump]
-quick
-set-variable = max_allowed_packet=16M
-
-[mysql]
-no-auto-rehash
-#safe-updates # Remove the comment character if you are not familiar with SQL
-
-[isamchk]
-set-variable = key_buffer=128M
-set-variable = sort_buffer=128M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
-
-[myisamchk]
-set-variable = key_buffer=128M
-set-variable = sort_buffer=128M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
diff --git a/support-files/Attic/my-medium.cfg.sh b/support-files/Attic/my-medium.cfg.sh
deleted file mode 100644
index 18c297fe151..00000000000
--- a/support-files/Attic/my-medium.cfg.sh
+++ /dev/null
@@ -1,58 +0,0 @@
-# Example mysql config file for medium systems.
-#
-# This is for a system with little memory (32M - 64M) where MySQL plays
-# a important part and systems up to 128M very MySQL is used together with
-# other programs (like a web server)
-#
-# You can copy this file to
-# /etc/mf.cnf to set global options,
-# mysql-data-dir/my.cnf to set server-specific options (in this
-# installation this directory is @localstatedir@) or
-# ~/.my.cnf to set user-specific options.
-#
-# One can in this file use all long options that the program supports.
-# If you want to know which options a program support, run the program
-# with --help option.
-
-# The following options will be passed to all MySQL clients
-[client]
-#password = your_password
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-
-# Here follows entries for some specific programs
-
-# The MySQL server
-[mysqld]
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-#tmpdir = /tmp/ # Put this on a dedicated disk
-skip-locking
-set-variable = key_buffer=16M
-set-variable = max_allowed_packet=1M
-set-variable = table_cache=64
-set-variable = sort_buffer=512K
-set-variable = net_buffer_length=8K
-set-variable = myisam_sort_buffer_size=8M
-#set-variable = bdb_cache_size=1M
-log-update
-
-[mysqldump]
-quick
-set-variable = max_allowed_packet=16M
-
-[mysql]
-no-auto-rehash
-#safe-updates # Remove the comment character if you are not familiar with SQL
-
-[isamchk]
-set-variable = key_buffer=20M
-set-variable = sort_buffer=20M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
-
-[myisamchk]
-set-variable = key_buffer=20M
-set-variable = sort_buffer=20M
-set-variable = read-buffer=2M
-set-variable = write-buffer=2M
diff --git a/support-files/Attic/my-small.cfg.sh b/support-files/Attic/my-small.cfg.sh
deleted file mode 100644
index 69a816da3fb..00000000000
--- a/support-files/Attic/my-small.cfg.sh
+++ /dev/null
@@ -1,53 +0,0 @@
-# Example mysql config file for small systems.
-#
-# This is for a system with little memory (<= 64M) where MySQL is only used
-# from time to time and it's important that the mysqld deamon
-# doesn't use much resources.
-#
-# You can copy this file to
-# /etc/mf.cnf to set global options,
-# mysql-data-dir/my.cnf to set server-specific options (in this
-# installation this directory is @localstatedir@) or
-# ~/.my.cnf to set user-specific options.
-#
-# One can in this file use all long options that the program supports.
-# If you want to know which options a program support, run the program
-# with --help option.
-
-# The following options will be passed to all MySQL clients
-[client]
-#password = your_password
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-
-# Here follows entries for some specific programs
-
-# The MySQL server
-[mysqld]
-port = @MYSQL_TCP_PORT@
-socket = @MYSQL_UNIX_ADDR@
-skip-locking
-set-variable = key_buffer=16K
-set-variable = max_allowed_packet=1M
-set-variable = thread_stack=64K
-set-variable = table_cache=4
-set-variable = sort_buffer=64K
-set-variable = net_buffer_length=2K
-# Don't log things
-#log
-
-[mysqldump]
-quick
-set-variable = max_allowed_packet=16M
-
-[mysql]
-no-auto-rehash
-#safe-updates # Remove the comment character if you are not familiar with SQL
-
-[isamchk]
-set-variable = key_buffer=8M
-set-variable = sort_buffer=8M
-
-[myisamchk]
-set-variable = key_buffer=8M
-set-variable = sort_buffer=8M