aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/callbacks.c2
-rw-r--r--src/util.c9
-rw-r--r--src/util.h1
-rw-r--r--src/uzbl-core.c2
4 files changed, 2 insertions, 12 deletions
diff --git a/src/callbacks.c b/src/callbacks.c
index c261234..9bc5c28 100644
--- a/src/callbacks.c
+++ b/src/callbacks.c
@@ -441,7 +441,7 @@ void
progress_change_cb (WebKitWebView* web_view, GParamSpec param_spec) {
(void) param_spec;
int progress = webkit_web_view_get_progress(web_view) * 100;
- gchar *prg_str = itos(progress);
+ gchar *prg_str = g_strdup_printf("%d", progress);
send_event(LOAD_PROGRESS, prg_str, NULL);
g_free(prg_str);
}
diff --git a/src/util.c b/src/util.c
index f56eb57..ead07b5 100644
--- a/src/util.c
+++ b/src/util.c
@@ -177,15 +177,6 @@ find_existing_file(gchar* path_list) {
return NULL;
}
-
-char*
-itos(int val) {
- char tmp[20];
-
- snprintf(tmp, sizeof(tmp), "%i", val);
- return g_strdup(tmp);
-}
-
gchar*
argv_idx(const GArray *a, const guint idx) {
return g_array_index(a, gchar*, idx);
diff --git a/src/util.h b/src/util.h
index 388c202..87fe53a 100644
--- a/src/util.h
+++ b/src/util.h
@@ -16,5 +16,4 @@ char* str_replace(const char* search, const char* replace, const char* str
gboolean for_each_line_in_file(const gchar *path, void (*callback)(const gchar *l, void *c), void *user_data);
enum exp_type get_exp_type(const gchar*);
gchar* find_existing_file(gchar*);
-char* itos(int val);
gchar* argv_idx(const GArray*, const guint);
diff --git a/src/uzbl-core.c b/src/uzbl-core.c
index 129d14a..4c709f7 100644
--- a/src/uzbl-core.c
+++ b/src/uzbl-core.c
@@ -1782,7 +1782,7 @@ main (int argc, char* argv[]) {
send_event(INSTANCE_START, uzbl.info.pid_str, NULL);
if (uzbl.state.plug_mode) {
- char *t = itos(gtk_plug_get_id(uzbl.gui.plug));
+ char *t = g_strdup_printf("%d", gtk_plug_get_id(uzbl.gui.plug));
send_event(PLUG_CREATED, t, NULL);
g_free(t);
}