From 00eb4ec9af3d2a9c6e1dcbdde0abc068fda15dca Mon Sep 17 00:00:00 2001 From: Phil Date: Sat, 29 Mar 2008 12:44:29 +0000 Subject: [PATCH] some relocation of header includes * conky.h must come first, because it includes config.h which again defines _GNU_SOURCE, which is necessary for strdup() & Co. * declaring cpu_separate in top.h makes no sense, as it includes conky.h which declares cpu_separate itself git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky1@1078 7f574dfc-610e-0410-a909-a81674777703 --- src/diskio.c | 2 +- src/libmpdclient.c | 1 + src/mixer.c | 3 +-- src/prss.c | 4 ++-- src/rss.c | 4 ++-- src/top.h | 6 ------ 6 files changed, 7 insertions(+), 13 deletions(-) diff --git a/src/diskio.c b/src/diskio.c index 66cde04b..15dd30b0 100644 --- a/src/diskio.c +++ b/src/diskio.c @@ -27,8 +27,8 @@ * $Id$ */ -#include #include "conky.h" +#include static struct diskio_stat diskio_stats_[MAX_DISKIO_STATS]; struct diskio_stat *diskio_stats = diskio_stats_; diff --git a/src/libmpdclient.c b/src/libmpdclient.c index 67bfbb0b..30ab8065 100644 --- a/src/libmpdclient.c +++ b/src/libmpdclient.c @@ -29,6 +29,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "conky.h" #include "libmpdclient.h" #include diff --git a/src/mixer.c b/src/mixer.c index 4c001eea..674e89b0 100644 --- a/src/mixer.c +++ b/src/mixer.c @@ -25,14 +25,13 @@ * * $Id$ */ +#include "conky.h" #include - #include #include #include #include -#include "conky.h" #ifdef HAVE_LINUX_SOUNDCARD_H #include diff --git a/src/prss.c b/src/prss.c index 5a57f6b2..ad7cf7fe 100644 --- a/src/prss.c +++ b/src/prss.c @@ -15,13 +15,13 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +#include "config.h" +#include "prss.h" #include #include #include #include #include -#include "prss.h" -#include "config.h" #ifndef PARSE_OPTIONS #define PARSE_OPTIONS 0 diff --git a/src/rss.c b/src/rss.c index f1b69fb4..e185669e 100644 --- a/src/rss.c +++ b/src/rss.c @@ -25,15 +25,15 @@ * * $Id$ */ +#include "conky.h" +#include "prss.h" #include #include #include #include -#include "prss.h" #include #include #include -#include "conky.h" #define MAX_FEEDS 16 diff --git a/src/top.h b/src/top.h index ebad73a7..45730437 100644 --- a/src/top.h +++ b/src/top.h @@ -73,12 +73,6 @@ #define PROCFS_CMDLINE_TEMPLATE "/proc/%d/cmdline" #define MAX_SP 10 // number of elements to sort -/****************************************** - * Globals * - ******************************************/ - -extern int cpu_separate; - /****************************************** * Process class * ******************************************/