1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-12-26 12:27:52 +00:00

Merge branch 'master' of git.omp.am:/home/omp/git/conky

This commit is contained in:
Cesare Tirabassi 2009-07-12 11:45:33 +02:00
commit df17a54301
3 changed files with 12 additions and 5 deletions

View File

@ -76,7 +76,11 @@
the other libs required (depending on your configure the other libs required (depending on your configure
options). You should be able to see which extra packages options). You should be able to see which extra packages
you need to install by reading errors that you get from you need to install by reading errors that you get from
'./configure'. './configure'. You can enable/disable stuff by giving
options to configure, but be careful with disabling. For
example: with --disable-math you won't get errors but
logarithmic graphs will be normal graphs and gauges
will miss their line.
</para> </para>
<para>Conky has (for some time) been available in the <para>Conky has (for some time) been available in the
repositories of most popular distributions. Here are some repositories of most popular distributions. Here are some

View File

@ -6536,8 +6536,10 @@ static void draw_line(char *s)
{ {
int h, by = 0; int h, by = 0;
unsigned long last_colour = current_color; unsigned long last_colour = current_color;
#ifdef MATH
float angle, px, py; float angle, px, py;
int usage; int usage;
#endif /* MATH */
if (cur_x - text_start_x > maximum_width if (cur_x - text_start_x > maximum_width
&& maximum_width > 0) { && maximum_width > 0) {
@ -7388,12 +7390,12 @@ static void main_loop(void)
break; break;
} }
#ifdef HAVE_SYS_INOTIFY_H #ifdef HAVE_SYS_INOTIFY_H
if (inotify_fd != -1 && inotify_config_wd == -1) { if (inotify_fd != -1 && inotify_config_wd == -1 && current_config != 0) {
inotify_config_wd = inotify_add_watch(inotify_fd, inotify_config_wd = inotify_add_watch(inotify_fd,
current_config, current_config,
IN_MODIFY); IN_MODIFY);
} }
if (inotify_fd != -1 && inotify_config_wd != -1) { if (inotify_fd != -1 && inotify_config_wd != -1 && current_config != 0) {
int len = 0, idx = 0; int len = 0, idx = 0;
fd_set descriptors; fd_set descriptors;
struct timeval time_to_wait; struct timeval time_to_wait;
@ -7583,6 +7585,7 @@ void clean_up(void)
} }
free(current_config); free(current_config);
current_config = 0;
#ifdef TCP_PORT_MONITOR #ifdef TCP_PORT_MONITOR
tcp_portmon_clear(); tcp_portmon_clear();

View File

@ -254,11 +254,11 @@ static void graph_append(struct special_t *graph, double f, char showaslog)
{ {
int i; int i;
#ifdef MATH
if (showaslog) { if (showaslog) {
#ifdef MATH
f = log10(f + 1); f = log10(f + 1);
}
#endif #endif
}
if (!graph->scaled && f > graph->graph_scale) { if (!graph->scaled && f > graph->graph_scale) {
f = graph->graph_scale; f = graph->graph_scale;