~ubuntu-branches/ubuntu/gutsy/gnome-system-monitor/gutsy

« back to all changes in this revision

Viewing changes to src/util.h

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2006-12-18 00:11:37 UTC
  • mfrom: (1.1.18 upstream)
  • Revision ID: james.westby@ubuntu.com-20061218001137-xqbegj3g7g92y982
Tags: 2.17.4-0ubuntu1
* New upstream version:
  - 100% C++.
  - Disabled libsexy because it is buggy and unmaintained.
  - Fixed build on solaris.
* debian/control.in:
  - doesn't Build-Depends on libpcre3-dev
  - doesn't Recommends libsexy2
* debian/patches/01_load_library_instead_of_so.patch:
  - updated
* debian/patches/02_lpi.patch:
  - updated
* debian/patches/03_autoconf.patch:
  - updated

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
#include <glib.h>
5
5
#include <libgnomevfs/gnome-vfs-utils.h>
6
6
#include <stddef.h>
7
 
 
8
 
#define PROCMAN_CMP(X, Y) (((X) == (Y)) ? 0 : (((X) < (Y)) ? -1 : 1))
9
 
#define PROCMAN_RCMP(X, Y) PROCMAN_CMP((Y), (X))
10
 
 
 
7
#include <string>
 
8
 
 
9
using std::string;
 
10
 
 
11
template<typename T>
 
12
inline int procman_cmp(T x, T y)
 
13
{
 
14
        if (x == y)
 
15
                return 0;
 
16
 
 
17
        if (x < y)
 
18
                return -1;
 
19
 
 
20
        return 1;
 
21
}
 
22
 
 
23
#define PROCMAN_CMP(X, Y) procman_cmp((X), (Y))
 
24
#define PROCMAN_RCMP(X, Y) procman_cmp((Y), (X));
11
25
 
12
26
GtkWidget*
13
27
procman_make_label_for_mmaps_or_ofiles(const char *format,
26
40
void
27
41
procman_debug(const char *format, ...) G_GNUC_INTERNAL G_GNUC_PRINTF(1, 2);
28
42
 
 
43
 
 
44
inline string make_string(char *c_str)
 
45
{
 
46
        string s(c_str);
 
47
        g_free(c_str);
 
48
        return s;
 
49
}
 
50
 
 
51
 
29
52
#endif /* H_GNOME_SYSTEM_MONITOR_UTIL_1123178725 */