summaryrefslogtreecommitdiff
path: root/fitz/base_string.c
AgeCommit message (Collapse)Author
2013-03-01Bug 693624: Ensure that windows copes with utf8 filenamesRobin Watts
When running under Windows, replace fopen with our own fopen_utf8 that converts from utf8 to unicode before calling the unicode version of fopen.
2013-01-11Bug 693503: Fix NULL dereference in atoi.Robin Watts
If a PDF xref subsection is broken in the wrong place, we can get NULL back from fz_strsep, which causes a SEGV when fed to atoi. Add a new fz_atoi that copes with NULL to avoid this. Problem found in a test file, 3959.pdf.SIGSEGV.ad4.3289 supplied by Mateusz "j00ru" Jurczyk and Gynvael Coldwind of the Google Security Team using Address Sanitizer. Many thanks!
2012-07-05Move to static inline functions from macros.Robin Watts
Instead of using macros for min/max/abs/clamp, we move to using inline functions. These are more typesafe, and should produce equivalent code on compilers that support inline (i.e. pretty much everything we care about these days). People can always do their own macro versions if they prefer.
2012-03-28Whitespace fixes.Tor Andersson
2012-03-12Merge branch 'master' into header-splitRobin Watts
2012-03-12Clamp real numbers when parsing.Sebastian Rasmussen
Instead of returning in 1.0 for underflow/overflow, return minimum value for underflow and maximum value for overflow. NaN returns 1.0.
2012-03-07More release tidyups.Robin Watts
Add some function documentation to fitz.h. Add fz_ prefix to runetochar, chartorune, runelen etc. Change fz_runetochar to avoid passing unnecessary pointer.
2012-03-07Splitting tweaks.Tor Andersson
2012-03-06Split fitz.h/mupdf.h into internal/external headers.Robin Watts
Attempt to separate public API from internal functions.
2011-12-08Stylistic changes when testing pointer values for NULL.Tor Andersson
Also: use 'cannot' instead of 'failed to' in error messages.
2011-05-31Fix assert in scale: see Bug 692245.Robin Watts
Bug 692245 gives a file that produces a runtime assert in mupdf due to an extremely large ctm offset (unrepresentable in a float). We fix our code here so that such floats are always read as 1.0. In this particular case, the exact value read doesn't seem to matter. We match acrobat. We pick 1.0 rather than 0.0 as this is less likely to provoke division by 0 errors later on.
2011-04-04Le Roi est mort, vive le Roi!Tor Andersson
The run-together words are dead! Long live the underscores! The postscript inspired naming convention of using all run-together words has served us well, but it is now time for more readable code. In this commit I have also added the sed script, rename.sed, that I used to convert the source. Use it on your patches and application code.
2010-12-30Adhere to nil idiom.Sebastian Rasmussen
2010-07-17Remove all trailing whitespace.Tor Andersson
2010-07-09Rearrange and merge some files in the fitz directory.Tor Andersson
2010-07-08Remove unmaintained MMX optimized function and runtime detection.Tor Andersson
2009-12-03Consolidate include lines to a single fitz.h.Tor Andersson
2009-11-29Fix up indentation.Tor Andersson
2009-07-08Fix a few occurrances of undeclared functions and functions that could be ↵Sebastian Rasmussen
static.
2009-03-11Add fz_catch function, and cause the throw/rethrow/catch functions to print ↵Tor Andersson
the errors immediately.