summaryrefslogtreecommitdiff
path: root/egg
diff options
context:
space:
mode:
authorPhilip Chimento <philip.chimento@gmail.com>2016-11-14 20:40:07 -0800
committerStef Walter <stefw@gnome.org>2016-11-15 13:44:26 +0100
commit097089bc983ec1d25210b96a98de1fd700d09702 (patch)
tree765f99822c8c38463f5787c11e12f864c7fec3a5 /egg
parent5d6f0536be1ec7a429d59abdb6b268c9b94e06ba (diff)
downloadgnome-keyring-097089bc983ec1d25210b96a98de1fd700d09702.tar.gz
egg-armor: Use g_strrstr_len() instead of memrchr()
Not all systems have memrchr(), so g_strrstr_len() is more portable, though probably slower. https://bugzilla.gnome.org/show_bug.cgi?id=774311
Diffstat (limited to 'egg')
-rw-r--r--egg/egg-armor.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/egg/egg-armor.c b/egg/egg-armor.c
index 23cfba5f..267cc87b 100644
--- a/egg/egg-armor.c
+++ b/egg/egg-armor.c
@@ -180,7 +180,7 @@ armor_find_end (const gchar *data,
* does not insist that we validate this line, and is more useful
* for PGP messages, rather than the keys we usually see.
*/
- line = memrchr (data, '\n', (pref - 1) - data);
+ line = g_strrstr_len (data, (pref - 1) - data, "\n");
if (line && line[1] == '=')
pref = line;