|Subject:||CHI::Driver::File should consult POSIX's PATH_MAX for max_key_length|
|X-Mailer:||MIME-tools 5.427 (Entity 5.427)|
Instead of requiring the user to eventually figure it out, the File driver should use a sane default for max_key_length based on POSIX's PATH_MAX, the root_dir, and expected length of the namespace, directories, etc. Windows only has a PATH_MAX of 260, so storage of any large keys will typically not work. Since there is no error message by default, it will be silently ignored. Here's a formula to use for setting a max_key_length: PATH_MAX - length( $root_dir->subdir($namespace, 0, 0) ) - 4 - 8 The 4 is the '.dat' extension, and the 8 is an extra margin of error.