Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
GIMP
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2,764
Issues
2,764
List
Boards
Labels
Service Desk
Milestones
Merge Requests
39
Merge Requests
39
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
External Wiki
External Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
GNOME
GIMP
Commits
2eb74bec
Commit
2eb74bec
authored
Nov 29, 2013
by
Michael Natterer
😴
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
app: add G_GNUC_PRINTF() to places where the args are a va_list
The trick is to use G_GNUC_PRINTF (n, 0).
parent
297ff1ea
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
31 deletions
+40
-31
app/core/gimp.h
app/core/gimp.h
+2
-2
app/display/gimpstatusbar.c
app/display/gimpstatusbar.c
+1
-1
app/display/gimpstatusbar.h
app/display/gimpstatusbar.h
+6
-6
app/gimp-log.h
app/gimp-log.h
+1
-1
app/widgets/gimpmessagebox.c
app/widgets/gimpmessagebox.c
+30
-21
No files found.
app/core/gimp.h
View file @
2eb74bec
...
...
@@ -203,12 +203,12 @@ void gimp_message (Gimp *gimp,
GObject
*
handler
,
GimpMessageSeverity
severity
,
const
gchar
*
format
,
...)
G_GNUC_PRINTF
(
4
,
5
);
...)
G_GNUC_PRINTF
(
4
,
5
);
void
gimp_message_valist
(
Gimp
*
gimp
,
GObject
*
handler
,
GimpMessageSeverity
severity
,
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
4
,
0
)
;
void
gimp_message_literal
(
Gimp
*
gimp
,
GObject
*
handler
,
GimpMessageSeverity
severity
,
...
...
app/display/gimpstatusbar.c
View file @
2eb74bec
...
...
@@ -120,7 +120,7 @@ static gboolean gimp_statusbar_temp_timeout (GimpStatusbar *statusbar)
static
void
gimp_statusbar_msg_free
(
GimpStatusbarMsg
*
msg
);
static
gchar
*
gimp_statusbar_vprintf
(
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
1
,
0
)
;
G_DEFINE_TYPE_WITH_CODE
(
GimpStatusbar
,
gimp_statusbar
,
GTK_TYPE_STATUSBAR
,
...
...
app/display/gimpstatusbar.h
View file @
2eb74bec
...
...
@@ -91,12 +91,12 @@ void gimp_statusbar_push (GimpStatusbar *statusbar
const
gchar
*
context
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
...)
G_GNUC_PRINTF
(
4
,
5
);
...)
G_GNUC_PRINTF
(
4
,
5
);
void
gimp_statusbar_push_valist
(
GimpStatusbar
*
statusbar
,
const
gchar
*
context
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
4
,
0
)
;
void
gimp_statusbar_push_coords
(
GimpStatusbar
*
statusbar
,
const
gchar
*
context
,
const
gchar
*
stock_id
,
...
...
@@ -117,12 +117,12 @@ void gimp_statusbar_replace (GimpStatusbar *statusbar
const
gchar
*
context
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
...)
G_GNUC_PRINTF
(
4
,
5
);
...)
G_GNUC_PRINTF
(
4
,
5
);
void
gimp_statusbar_replace_valist
(
GimpStatusbar
*
statusbar
,
const
gchar
*
context
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
4
,
0
)
;
const
gchar
*
gimp_statusbar_peek
(
GimpStatusbar
*
statusbar
,
const
gchar
*
context
);
void
gimp_statusbar_pop
(
GimpStatusbar
*
statusbar
,
...
...
@@ -132,12 +132,12 @@ void gimp_statusbar_push_temp (GimpStatusbar *statusbar
GimpMessageSeverity
severity
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
...)
G_GNUC_PRINTF
(
4
,
5
);
...)
G_GNUC_PRINTF
(
4
,
5
);
void
gimp_statusbar_push_temp_valist
(
GimpStatusbar
*
statusbar
,
GimpMessageSeverity
severity
,
const
gchar
*
stock_id
,
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
4
,
0
)
;
void
gimp_statusbar_pop_temp
(
GimpStatusbar
*
statusbar
);
void
gimp_statusbar_update_cursor
(
GimpStatusbar
*
statusbar
,
...
...
app/gimp-log.h
View file @
2eb74bec
...
...
@@ -57,7 +57,7 @@ void gimp_logv (GimpLogFlags flags,
const
gchar
*
function
,
gint
line
,
const
gchar
*
format
,
va_list
args
);
va_list
args
)
G_GNUC_PRINTF
(
4
,
0
)
;
#ifdef G_HAVE_ISO_VARARGS
...
...
app/widgets/gimpmessagebox.c
View file @
2eb74bec
...
...
@@ -42,27 +42,36 @@ enum
};
static
void
gimp_message_box_constructed
(
GObject
*
object
);
static
void
gimp_message_box_dispose
(
GObject
*
object
);
static
void
gimp_message_box_finalize
(
GObject
*
object
);
static
void
gimp_message_box_set_property
(
GObject
*
object
,
guint
property_id
,
const
GValue
*
value
,
GParamSpec
*
pspec
);
static
void
gimp_message_box_get_property
(
GObject
*
object
,
guint
property_id
,
GValue
*
value
,
GParamSpec
*
pspec
);
static
void
gimp_message_box_forall
(
GtkContainer
*
container
,
gboolean
include_internals
,
GtkCallback
callback
,
gpointer
callback_data
);
static
void
gimp_message_box_size_request
(
GtkWidget
*
widget
,
GtkRequisition
*
requisition
);
static
void
gimp_message_box_size_allocate
(
GtkWidget
*
widget
,
GtkAllocation
*
allocation
);
static
void
gimp_message_box_constructed
(
GObject
*
object
);
static
void
gimp_message_box_dispose
(
GObject
*
object
);
static
void
gimp_message_box_finalize
(
GObject
*
object
);
static
void
gimp_message_box_set_property
(
GObject
*
object
,
guint
property_id
,
const
GValue
*
value
,
GParamSpec
*
pspec
);
static
void
gimp_message_box_get_property
(
GObject
*
object
,
guint
property_id
,
GValue
*
value
,
GParamSpec
*
pspec
);
static
void
gimp_message_box_forall
(
GtkContainer
*
container
,
gboolean
include_internals
,
GtkCallback
callback
,
gpointer
callback_data
);
static
void
gimp_message_box_size_request
(
GtkWidget
*
widget
,
GtkRequisition
*
requisition
);
static
void
gimp_message_box_size_allocate
(
GtkWidget
*
widget
,
GtkAllocation
*
allocation
);
static
void
gimp_message_box_set_label_text
(
GimpMessageBox
*
box
,
gint
n
,
const
gchar
*
format
,
va_list
args
)
G_GNUC_PRINTF
(
3
,
0
);
static
void
gimp_message_box_set_label_markup
(
GimpMessageBox
*
box
,
gint
n
,
const
gchar
*
format
,
va_list
args
)
G_GNUC_PRINTF
(
3
,
0
);
G_DEFINE_TYPE
(
GimpMessageBox
,
gimp_message_box
,
GTK_TYPE_BOX
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment