Commit Graph

14 Commits

Author SHA1 Message Date
Adrien Destugues 91ec679f17 PVS V1010: access before start of buffer after fgets
Change-Id: I8cfa1e8a3c8dd8c2837e51756ac3eeaea1e756f0
Reviewed-on: https://review.haiku-os.org/c/1639
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2019-07-21 20:05:08 +00:00
Augustin Cavalier d113c00b5a Remove more HOST_PLATFORM_SUNOS cruft. 2018-11-23 16:29:57 -05:00
Ingo Weinhold 2b76973fa2 mimeset: Use TextSnifferAddon when using a custom MIME DB
That addresses the problem that packaged text files aren't correctly
identified (ticket #9972). All concerned packages have to be rebuilt,
of course.
2013-11-22 12:24:13 +01:00
Ingo Weinhold 0c61965f2b mimeset: Complete custom mime DB support
* Don't require the first MIME DB directory to exist anymore. Database
  creates it anyway.
* Make use of MimeInfoUpdater to support updating MIME info with a
  custom MIME DB.
* Make use of MimeEntryProcessor::DoRecursively() to support recursive
  operation with a custom MIME DB.
2013-05-09 03:22:24 +02:00
Ingo Weinhold 9ea1940c48 mimeset: WIP to support custom MIME DB directories
Add option -m/--mimedb for specifying one or more directories to be
used as the MIME DB instead of the system MIME DB. Currently only works
with --apps and only non-recursive.

When fully implemented the new feature will be used in the build system
and on Haiku when building packages to generated the MIME DB entries for
applications, so those can be included in the same package. Furthermore
it will be possible to use the MIME DB the build system already
generates to identify files before packaging them.
2013-05-08 04:51:48 +02:00
Ingo Weinhold a625f557c5 mimeset: Change options style
* Use "--" prefix for long options and switch to getopt parsing. There's
  still compatibility support for "-apps" and "-all", but they are
  considered obsolete, now.
* Add short options "-a" for "--apps", "-A" for "--all", and "-h" for
  "--help".
2013-05-07 16:27:06 +02:00
Ingo Weinhold f8d6e1f938 mimeset: Style update 2013-05-07 15:32:15 +02:00
Ingo Weinhold 4d121ec067 Patch by Andreas Faerber with changes by myself: Work towards Solaris
build platform support.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26899 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-08-09 15:36:24 +00:00
Stephan Aßmus 96e23ec325 * Check the return code of the functions that trigger the work in the
registrar.
* Added the constant names to the force parameter (as comments for now).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24292 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-07 16:07:06 +00:00
Michael Lotz 7f9939f06d Made a failing update_mime_info() non fatal. It seems that the BeOS version of mimeset does the same. Tested with FileType-F a mimeset under R5 does not quit with an error. This fixes the build on R5 and should therefore fix bug #1280.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21518 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-27 22:59:00 +00:00
Jérôme Duval 20bda75303 exit with 1 when an error occurs
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21494 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-22 16:23:51 +00:00
Jérôme Duval 29cb39c4ff actually exit with an error when it happens
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21484 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-21 18:40:33 +00:00
Axel Dörfler fd9772def6 Fixed build on BeOS: MimeType.h doesn't exist; we need to use Mime.h.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16135 a95241bf-73f2-0310-859d-f6bbb57e9c96
2006-01-29 14:25:27 +00:00
Axel Dörfler 4aab22ef1c Implemented the "mimeset" command.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14264 a95241bf-73f2-0310-859d-f6bbb57e9c96
2005-09-28 00:30:26 +00:00