From f9d99406aea10fb5f1d100007bd006adf0467819 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Wed, 4 Jul 2007 23:20:05 +0000 Subject: [PATCH] Fixed build under Dano (and probably Zeta, too); our headers used entry_ref resp. BDirectory without declaring it first. Since that's an actual bug, I made the changes in the Haiku headers, and copied them back to the build headers. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21562 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/build/os/app/Message.h | 2 ++ headers/build/os/storage/Node.h | 39 +++++++-------------------------- headers/os/app/Message.h | 2 ++ headers/os/storage/Node.h | 39 +++++++-------------------------- 4 files changed, 20 insertions(+), 62 deletions(-) diff --git a/headers/build/os/app/Message.h b/headers/build/os/app/Message.h index 3055eb6719..231c526c9d 100644 --- a/headers/build/os/app/Message.h +++ b/headers/build/os/app/Message.h @@ -8,6 +8,7 @@ #ifndef _MESSAGE_H #define _MESSAGE_H + #include #include #include @@ -21,6 +22,7 @@ class BBlockCache; class BMessenger; class BHandler; class BString; +struct entry_ref; // Name lengths and Scripting specifiers diff --git a/headers/build/os/storage/Node.h b/headers/build/os/storage/Node.h index e8ae591da2..39b21dce71 100644 --- a/headers/build/os/storage/Node.h +++ b/headers/build/os/storage/Node.h @@ -1,24 +1,14 @@ -//---------------------------------------------------------------------- -// This software is part of the OpenBeOS distribution and is covered -// by the OpenBeOS license. -//--------------------------------------------------------------------- -/*! - \file Node.h - BNode and node_ref interface declarations. -*/ - +/* + * Copyright 2002-2007, Haiku, Inc. All Rights Reserved. + * Distributed under the terms of the MIT License. + */ #ifndef _NODE_H #define _NODE_H + #include -#ifdef USE_OPENBEOS_NAMESPACE -namespace OpenBeOS { -#endif - -//--------------------------------------------------------------- -// node_ref -//--------------------------------------------------------------- +class BDirectory; //! Reference structure to a particular vnode on a particular device /*! node_ref - A node reference. @@ -30,7 +20,7 @@ namespace OpenBeOS { struct node_ref { node_ref(); node_ref(const node_ref &ref); - + bool operator==(const node_ref &ref) const; bool operator!=(const node_ref &ref) const; node_ref& operator=(const node_ref &ref); @@ -40,16 +30,12 @@ struct node_ref { return (device < ref.device || device == ref.device && node < ref.node); } - + dev_t device; ino_t node; }; -//--------------------------------------------------------------- -// BNode -//--------------------------------------------------------------- - //! A BNode represents a chunk of data in the filesystem. /*! The BNode class provides an interface for manipulating the data and attributes belonging to filesystem entries. The BNode is unaware of the name that refers @@ -63,7 +49,6 @@ struct node_ref { */ class BNode : public BStatable { public: - BNode(); BNode(const entry_ref *ref); BNode(const BEntry *entry); @@ -136,12 +121,4 @@ private: status_t InitAttrDir(); }; - - -#ifdef USE_OPENBEOS_NAMESPACE -}; // namespace OpenBeOS -#endif - #endif // _NODE_H - - diff --git a/headers/os/app/Message.h b/headers/os/app/Message.h index 0a626bb3f8..de75db48ad 100644 --- a/headers/os/app/Message.h +++ b/headers/os/app/Message.h @@ -8,6 +8,7 @@ #ifndef _MESSAGE_H #define _MESSAGE_H + #include #include #include @@ -21,6 +22,7 @@ class BBlockCache; class BMessenger; class BHandler; class BString; +struct entry_ref; // Name lengths and Scripting specifiers diff --git a/headers/os/storage/Node.h b/headers/os/storage/Node.h index 91f533a015..f6a663e1d1 100644 --- a/headers/os/storage/Node.h +++ b/headers/os/storage/Node.h @@ -1,24 +1,14 @@ -//---------------------------------------------------------------------- -// This software is part of the OpenBeOS distribution and is covered -// by the OpenBeOS license. -//--------------------------------------------------------------------- -/*! - \file Node.h - BNode and node_ref interface declarations. -*/ - +/* + * Copyright 2002-2007, Haiku, Inc. All Rights Reserved. + * Distributed under the terms of the MIT License. + */ #ifndef _NODE_H #define _NODE_H + #include -#ifdef USE_OPENBEOS_NAMESPACE -namespace OpenBeOS { -#endif - -//--------------------------------------------------------------- -// node_ref -//--------------------------------------------------------------- +class BDirectory; //! Reference structure to a particular vnode on a particular device /*! node_ref - A node reference. @@ -30,20 +20,16 @@ namespace OpenBeOS { struct node_ref { node_ref(); node_ref(const node_ref &ref); - + bool operator==(const node_ref &ref) const; bool operator!=(const node_ref &ref) const; node_ref& operator=(const node_ref &ref); - + dev_t device; ino_t node; }; -//--------------------------------------------------------------- -// BNode -//--------------------------------------------------------------- - //! A BNode represents a chunk of data in the filesystem. /*! The BNode class provides an interface for manipulating the data and attributes belonging to filesystem entries. The BNode is unaware of the name that refers @@ -57,7 +43,6 @@ struct node_ref { */ class BNode : public BStatable { public: - BNode(); BNode(const entry_ref *ref); BNode(const BEntry *entry); @@ -130,12 +115,4 @@ private: status_t InitAttrDir(); }; - - -#ifdef USE_OPENBEOS_NAMESPACE -}; // namespace OpenBeOS -#endif - #endif // _NODE_H - -