Commit Graph

27 Commits

Author SHA1 Message Date
Stephan Aßmus d4d27fac86 * Rewrote MediaDefs.h and MediaEncoder.h
* Moved MediaKit errors into Errors.h


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32779 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-28 12:42:36 +00:00
Axel Dörfler d7571ebcf7 * Rewrote headers as needed.
* Cleaned up our own headers.
* Moved translator errors into Errors.h.
* Removed extra TranslationKit.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32755 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-27 14:20:56 +00:00
Ingo Weinhold 7c44760049 Added ENOATTR.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32425 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-15 21:20:05 +00:00
Ingo Weinhold 39d58e2f49 Experimental approach to tackle the problem with Be's negative error codes and
ported software:
* If the macro B_USE_POSITIVE_POSIX_ERRORS is defined the POSIX error code
  constants (ENOMEM, EINTR,...) will have positive values.
* Introduced the macros B_TO_{POSITIVE,NEGATIVE}_ERROR() which do convert a
  given error code to a positive/negative value.
* Added static library libposix_error_mapper.a that overrides all POSIX
  functions (save the ones I forgot to add :-)) directly meddling with error
  codes (having them as parameter or returning them) dealing with the
  positive<->negative error code conversions. The functions have hidden
  visibility, so they affect only the shared object they are linked into.
* So ideally all one has to do is to build a ported software with
  -DB_USE_POSITIVE_POSIX_ERRORS and -lposix_error_mapper and be good with
  respect to error code problems.
* Potential issues:
  - When mixing ported and Haiku native code, i.e. using Haiku native code in
    a ported software or using a ported library in a Haiku native application
    care must be taken to convert error codes where the two interface. That's
    what the B_TO_{POSITIVE,NEGATIVE}_ERROR() macros are supposed to be used
    for.
  - A ported static library can obviously not be linked directly against
    -lposix_error_mapper. The shared object linking a against the ported static
    library has to do that. The previous point applies when that causes mixing
    with Haiku native code.
  - When dependent ported libraries are used probably all of them should use
    the error mapping.

Comments welcome.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29653 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-22 15:43:03 +00:00
Ingo Weinhold 965aa03f49 Changed all error codes from enum values to macros. This allows for
compile time checks. Incidently those are not totally uncommon in
portable code.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25385 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-08 20:54:14 +00:00
Ingo Weinhold 2c97a8d164 Use -I instead of -isystem for system header directories when building
with gcc 4. Fixed resulting build errors (gcc is more lenient for
headers in -isystem directories).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20386 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-14 20:36:42 +00:00
Axel Dörfler 4a50aa51f2 Applied another patch by Vasilis: this one replaces all C++ style comments with
C style ones, as this is a C header, too (and a very basic one).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19984 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-01-27 16:26:37 +00:00
Axel Dörfler 686bdd59d3 Rewritten Errors.h, courtesy of Vasilis Kaoutsis - thanks for all the work!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19979 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-01-26 22:11:00 +00:00
Bruno G. Albuquerque 92c6f0417b How could we live without this?
Added B_DONT_DO_THAT error define.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18256 a95241bf-73f2-0310-859d-f6bbb57e9c96
2006-07-24 22:52:56 +00:00
Axel Dörfler b2b2b75a41 Fixed some style issues. Happy recompiling! :-)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17092 a95241bf-73f2-0310-859d-f6bbb57e9c96
2006-04-11 18:50:48 +00:00
Ingo Weinhold a406236dc2 New error codes:
- B_SHUTDOWN_CANCELLED: The shutdown process was cancelled (most likely by
  the user).
- B_SHUTTING_DOWN: An operation cannot be performed, since the system is
  shutting down (e.g. BApplication creation).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13413 a95241bf-73f2-0310-859d-f6bbb57e9c96
2005-07-03 16:50:29 +00:00
Axel Dörfler ec5a9998df Added a B_NOT_SUPPORTED synonym for EOPNOTSUPP.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12250 a95241bf-73f2-0310-859d-f6bbb57e9c96
2005-04-05 13:56:16 +00:00
Axel Dörfler ae614d48fc Some minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12242 a95241bf-73f2-0310-859d-f6bbb57e9c96
2005-04-04 23:00:48 +00:00
Jérôme Duval 9f20e1783b added some missing posix error codes. i don't know if they exist as BeOS error codes at all
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11536 a95241bf-73f2-0310-859d-f6bbb57e9c96
2005-03-02 16:42:07 +00:00
Axel Dörfler a4733dd5dd Added some more error message found in Dano headers - not sure if we'll keep them, though.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7628 a95241bf-73f2-0310-859d-f6bbb57e9c96
2004-05-23 23:21:20 +00:00
Axel Dörfler 154aaaf273 Removed B_NOT_SUPPORTED again - EOPNOTSUPP is a socket specific error code
and it should have read B_NOT_SUPPORTED_ON_SOCKET.
We could reintroduce it later (along with other missing network errors).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3552 a95241bf-73f2-0310-859d-f6bbb57e9c96
2003-06-17 00:38:45 +00:00
Axel Dörfler 9de96ae6c6 Changed new codes after suggestions from Ingo and Marcus.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3549 a95241bf-73f2-0310-859d-f6bbb57e9c96
2003-06-17 00:08:33 +00:00
Axel Dörfler 68145d0df8 Added some new B_* names for existing POSIX error codes - please review.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3547 a95241bf-73f2-0310-859d-f6bbb57e9c96
2003-06-16 20:37:43 +00:00
ejakowatz d2f82aa6e3 Added B_NOT_A_MESSAGE error code (borrowed from Dano).
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2268 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-12-18 07:33:55 +00:00
beveloper 0e2e5d7f76 added EHOSTDOWN, required by the net kit.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1770 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-10-29 20:33:01 +00:00
lillo 343b352fe1 Signals, 2nd pass: syscall restarting now only works on EINTR (removed other exotic retcodes like ERESTARTSYS); signal handlers now receive 3 args, and the vregs struct is used to save the signal context, making the system beos compatible.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1681 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-10-26 13:31:22 +00:00
lillo f510e6ce60 posix signals support, 1st pass
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1623 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-10-23 17:31:10 +00:00
Axel Dörfler c3db7c3b9e Added the B_BAD_DATA error.
Removed all the whitespaces at the end of every line.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@393 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-07-23 14:03:46 +00:00
David Reid afe886fc48 Obey the gods of source compatability. Progress is evil. (apparently)
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@136 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-07-12 14:57:37 +00:00
David Reid f16873a60e OK, final change to error codes for a while I hope.
- remove private/kernel/Errors.h as this was just plain wrong to have it
  there and confused issues somewhat.
- add the kerrors.h file that has kernel only error codes, namely the
  ERR_ codes from newos.
- add comments for the other header files to tell people where to find
  error code definitions in an attempt to stop people getting lost!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@101 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-07-11 22:17:09 +00:00
David Reid d69c1d7983 Move errno.h to it's correct place
Adjust Errors.h to use errno.h for the posix error codes
add first stab at limits.h, albeit not using the gcc headers at
present for intel.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@88 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-07-11 20:39:30 +00:00
ejakowatz 52a3801208 It is accomplished ...
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-07-09 12:24:59 +00:00