mirror of
https://github.com/irssi/irssi.git
synced 2026-08-11 04:43:34 +02:00
uptime command by Lauri Nurmi with some modifications by me, bug #458.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4389 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
49d7e3981e
commit
9da0ca72a5
5 changed files with 25 additions and 3 deletions
|
|
@ -61,6 +61,7 @@ void log_away_deinit(void);
|
|||
int irssi_gui;
|
||||
int irssi_init_finished;
|
||||
int reload_config;
|
||||
time_t client_start_time;
|
||||
|
||||
static char *irssi_dir, *irssi_config_file;
|
||||
static GSList *dialog_type_queue, *dialog_text_queue;
|
||||
|
|
@ -215,6 +216,7 @@ void core_init(int argc, char *argv[])
|
|||
{
|
||||
dialog_type_queue = NULL;
|
||||
dialog_text_queue = NULL;
|
||||
client_start_time = time(NULL);
|
||||
|
||||
modules_init();
|
||||
#ifndef WIN32
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
#ifndef __IRSSI_CORE_H
|
||||
#define __IRSSI_CORE_H
|
||||
|
||||
#include <time.h>
|
||||
|
||||
/* for determining what GUI is currently in use: */
|
||||
#define IRSSI_GUI_NONE 0
|
||||
#define IRSSI_GUI_TEXT 1
|
||||
|
|
@ -12,6 +14,7 @@
|
|||
extern int irssi_gui;
|
||||
extern int irssi_init_finished; /* TRUE after "irssi init finished" signal is sent */
|
||||
extern int reload_config; /* TRUE after received SIGHUP. */
|
||||
extern time_t client_start_time;
|
||||
|
||||
void core_init_paths(int argc, char *argv[]);
|
||||
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@
|
|||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include "core.h"
|
||||
#include "module.h"
|
||||
#include "modules.h"
|
||||
#include "signals.h"
|
||||
|
|
@ -52,7 +53,6 @@ static int timer_tag;
|
|||
|
||||
static EXPANDO_REC *char_expandos[255];
|
||||
static GHashTable *expandos;
|
||||
static time_t client_start_time;
|
||||
static char *last_sent_msg, *last_sent_msg_body;
|
||||
static char *last_privmsg_from, *last_public_from;
|
||||
static char *sysname, *sysrelease, *sysarch;
|
||||
|
|
@ -577,7 +577,6 @@ void expandos_init(void)
|
|||
settings_add_str("lookandfeel", "timestamp_format", "%H:%M");
|
||||
settings_add_bool("lookandfeel", "chanmode_expando_strip", FALSE);
|
||||
|
||||
client_start_time = time(NULL);
|
||||
last_sent_msg = NULL; last_sent_msg_body = NULL;
|
||||
last_privmsg_from = NULL; last_public_from = NULL;
|
||||
last_timestamp = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue