After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 320246 - patch for g_return_* macros in static functions
patch for g_return_* macros in static functions
Status: RESOLVED FIXED
Product: eel
Classification: Deprecated
Component: general
2.16.x
Other All
: High enhancement
: 2.16.x
Assigned To: Nautilus Maintainers
Nautilus Maintainers
Depends on:
Blocks:
 
 
Reported: 2005-10-30 17:11 UTC by aaditya sood
Modified: 2008-03-28 14:34 UTC
See Also:
GNOME target: ---
GNOME version: 2.15/2.16


Attachments
patch for changing g_return_ macros in static function to g_assert() (39.11 KB, patch)
2005-10-30 17:19 UTC, aaditya sood
reviewed Details | Review

Description aaditya sood 2005-10-30 17:11:33 UTC
Distribution/Version: Ubuntu/Dapper

As per the details here
http://mail.gnome.org/archives/performance-list/2005-October/msg00005.html

Replacing g_return_ functions in internal (static) functions with g_assert macros.

For now I've replaced bulk of the calls with g_assert(), and in some places
'if() return' calls. If someone can review the patch and let me know what else
to fix/change, I'd be glad to work on them.

Patch to follow
Comment 1 aaditya sood 2005-10-30 17:19:20 UTC
Created attachment 54092 [details] [review]
patch for changing g_return_ macros in static function to g_assert()

Attaching patch
Comment 2 Christian Neumair 2006-03-18 11:33:47 UTC
Thanks for your efforts and your patch, and sorry for the late response!

Maybe you could send this patch to the nautilus mailing list [1] for review?

[1] http://mail.gnome.org/mailman/listinfo/nautilus-list
Comment 3 Christian Neumair 2006-09-19 20:39:05 UTC
Ping. Updating version.
Comment 4 Christian Neumair 2008-03-28 14:34:10 UTC
Thanks for your efforts!

I committed a slightly modified version, which also uses g_asserts() for the 

  g_return_val_if_fail(x, y)

checks where you used

  if (!x) return y;

I also replaced the  g_return_val_if_fail() calls in static functions by asserts, and added some g_return_...() checks to the public API.

http://svn.gnome.org/viewvc/eel?view=revision&revision=2098

Closing bug, marking as FIXED.

It would be great if you could also do the same for Nautilus :).