[dia] Use g_stat() rather than stat()
- From: Hans Breuer <hans src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [dia] Use g_stat() rather than stat()
- Date: Wed, 19 Aug 2009 13:40:07 +0000 (UTC)
commit d97d7bfb5c46aeeb7c64c17ffccb5f8fd0d34202
Author: Hans Breuer <hans breuer org>
Date: Wed Aug 19 15:18:53 2009 +0200
Use g_stat() rather than stat()
objects/custom/custom_object.c | 3 ++-
objects/custom_lines/custom_linetypes.c | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/objects/custom/custom_object.c b/objects/custom/custom_object.c
index 4141c39..a1cdad9 100644
--- a/objects/custom/custom_object.c
+++ b/objects/custom/custom_object.c
@@ -35,6 +35,7 @@
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
+#include <glib/gstdio.h>
#include "intl.h"
#include "shape_info.h"
@@ -1811,7 +1812,7 @@ custom_object_new(ShapeInfo *info, DiaObjectType **otype)
if (info->icon) {
struct stat buf;
- if (0==stat(info->icon,&buf)) {
+ if (0==g_stat(info->icon,&buf)) {
obj->pixmap = NULL;
obj->pixmap_file = info->icon;
} else {
diff --git a/objects/custom_lines/custom_linetypes.c b/objects/custom_lines/custom_linetypes.c
index 68b6758..e20c413 100644
--- a/objects/custom_lines/custom_linetypes.c
+++ b/objects/custom_lines/custom_linetypes.c
@@ -31,6 +31,7 @@
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
+#include <glib/gstdio.h>
#include "object.h"
@@ -256,7 +257,7 @@ custom_linetype_new(LineInfo *info, DiaObjectType **otype)
if (info->icon_filename) {
struct stat buf;
- if (0==stat(info->icon_filename,&buf)) {
+ if (0==g_stat(info->icon_filename,&buf)) {
obj->pixmap = NULL;
obj->pixmap_file = info->icon_filename;
} else {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]