Update of /cvsroot/ufraw/ufraw In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv31454
Modified Files: dcraw_api.cc Log Message: Fix crash with Foveon *.X3F files. Index: dcraw_api.cc =================================================================== RCS file: /cvsroot/ufraw/ufraw/dcraw_api.cc,v retrieving revision 1.88 retrieving revision 1.89 diff -u -d -r1.88 -r1.89 --- dcraw_api.cc 2 Feb 2013 18:00:09 -0000 1.88 +++ dcraw_api.cc 12 Mar 2013 05:00:07 -0000 1.89 @@ -215,7 +215,6 @@ } h->raw.height = d->iheight = (h->height + h->shrink) >> h->shrink; h->raw.width = d->iwidth = (h->width + h->shrink) >> h->shrink; - d->meta_data = (char *)(d->image + d->iheight * d->iwidth); /* copied from the end of dcraw's identify() */ if (d->filters && d->colors == 3) { d->filters |= ((d->filters >> 2 & 0x22222222) | @@ -223,12 +222,13 @@ } h->raw.colors = d->colors; h->fourColorFilters = d->filters; - if (d->filters) { + if (d->filters || d->colors == 1) { d->raw_image = (ushort *) g_malloc((d->raw_height + 7) * d->raw_width * 2); } else { h->raw.image = d->image = g_new0(dcraw_image_type, d->iheight * d->iwidth + d->meta_length); } + d->meta_data = (char *)(d->image + d->iheight * d->iwidth); d->dcraw_message(DCRAW_VERBOSE, _("Loading %s %s image from %s ...\n"), d->make, d->model, d->ifname_display); fseek(d->ifp, 0, SEEK_END); ------------------------------------------------------------------------------ Symantec Endpoint Protection 12 positioned as A LEADER in The Forrester Wave(TM): Endpoint Security, Q1 2013 and "remains a good choice" in the endpoint security space. For insight on selecting the right partner to tackle endpoint security challenges, access the full report. http://p.sf.net/sfu/symantec-dev2dev _______________________________________________ ufraw-cvs mailing list ufraw-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ufraw-cvs