Mercurial > pidgin.yaz
comparison libpurple/protocols/mxit/profile.c @ 32365:e8d4755ef84b
Don't use strlen() when you're just checking whether a string is
empty
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 22 Aug 2011 02:11:36 +0000 |
parents | 323876c34a96 |
children | 99ca503ea087 |
comparison
equal
deleted
inserted
replaced
32364:323876c34a96 | 32365:e8d4755ef84b |
---|---|
113 { | 113 { |
114 time_t t; | 114 time_t t; |
115 struct tm now, bdate; | 115 struct tm now, bdate; |
116 int age; | 116 int age; |
117 | 117 |
118 if ( ( !date ) || ( strlen( date ) == 0 ) ) | 118 if ( ( !date ) || ( !*date ) ) |
119 return 0; | 119 return 0; |
120 | 120 |
121 /* current time */ | 121 /* current time */ |
122 t = time( NULL ); | 122 t = time( NULL ); |
123 localtime_r( &t, &now ); | 123 localtime_r( &t, &now ); |