*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
if (basetmp == NULL)
basetmp = "mimetmp";
basetmp = g_path_get_basename(basetmp);
- if (*basetmp == '\0') basetmp = g_strdup("mimetmp");
+ if (*basetmp == '\0')
+ basetmp = g_strdup("mimetmp");
base = conv_filename_from_utf8(basetmp);
+ g_free(basetmp);
subst_for_shellsafe_filename(base);
}
value[0] = '\0';
value++;
+ while (value[0] == ' ')
+ value++;
g_strdown(attribute);
*tmp = '\0';
}
+ if (attribute) {
+ while (attribute[0] == ' ')
+ attribute++;
+ while (attribute[strlen(attribute)-1] == ' ')
+ attribute[strlen(attribute)-1] = '\0';
+ }
+ if (value) {
+ while (value[0] == ' ')
+ value++;
+ while (value[strlen(value)-1] == ' ')
+ value[strlen(value)-1] = '\0';
+ }
if (strrchr(attribute, '*') != NULL) {
gchar *tmpattr;