summaryrefslogtreecommitdiff
path: root/ext/dbase
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2007-08-10 08:56:23 +0000
committerAntony Dovgal <tony2001@php.net>2007-08-10 08:56:23 +0000
commita6c19f6ede4118ef919af87a9f8c8b9265093872 (patch)
tree3401602706b2d8c82fe1563b52f53f850eb446ee /ext/dbase
parentc581da4b5610b8b0ab6ff8db27078d8b1f9c63dd (diff)
downloadphp-git-a6c19f6ede4118ef919af87a9f8c8b9265093872.tar.gz
MFB: Fixed bug #42261 (header wrong for date field)
Diffstat (limited to 'ext/dbase')
-rw-r--r--ext/dbase/dbf_head.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/ext/dbase/dbf_head.c b/ext/dbase/dbf_head.c
index 33e3a425d7..c99bc1ba1f 100644
--- a/ext/dbase/dbf_head.c
+++ b/ext/dbase/dbf_head.c
@@ -154,12 +154,15 @@ int get_dbf_field(dbhead_t *dbh, dbfield_t *dbf)
switch (dbf->db_type) {
case 'N':
case 'F':
- dbf->db_flen = dbfield.dbf_flen[0];
- dbf->db_fdc = dbfield.dbf_flen[1];
- break;
+ dbf->db_flen = dbfield.dbf_flen[0];
+ dbf->db_fdc = dbfield.dbf_flen[1];
+ break;
+ case 'D':
+ dbf->db_flen = 8;
+ break;
default:
dbf->db_flen = get_short(dbfield.dbf_flen);
- break;
+ break;
}
if ((dbf->db_format = get_dbf_f_fmt(dbf)) == NULL) {