Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(476)

Side by Side Diff: base/third_party/xdg_mime/xdgmimemagic.c

Issue 10824186: Linux: update base/third_party/xdg_mime from upstream. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/third_party/xdg_mime/xdgmimeint.c ('k') | base/third_party/xdg_mime/xdgmimeparent.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* -*- mode: C; c-file-style: "gnu" -*- */ 1 /* -*- mode: C; c-file-style: "gnu" -*- */
2 /* xdgmimemagic.: Private file. Datastructure for storing magic files. 2 /* xdgmimemagic.: Private file. Datastructure for storing magic files.
3 * 3 *
4 * More info can be found at http://www.freedesktop.org/standards/ 4 * More info can be found at http://www.freedesktop.org/standards/
5 * 5 *
6 * Copyright (C) 2003 Red Hat, Inc. 6 * Copyright (C) 2003 Red Hat, Inc.
7 * Copyright (C) 2003 Jonathan Blandford <jrb@alum.mit.edu> 7 * Copyright (C) 2003 Jonathan Blandford <jrb@alum.mit.edu>
8 * 8 *
9 * Licensed under the Academic Free License version 2.0 9 * Licensed under the Academic Free License version 2.0
10 * Or under the following terms: 10 * Or under the following terms:
11 * 11 *
12 * This library is free software; you can redistribute it and/or 12 * This library is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU Lesser General Public 13 * modify it under the terms of the GNU Lesser General Public
14 * License as published by the Free Software Foundation; either 14 * License as published by the Free Software Foundation; either
15 * version 2 of the License, or (at your option) any later version. 15 * version 2 of the License, or (at your option) any later version.
16 * 16 *
17 * This library is distributed in the hope that it will be useful, 17 * This library is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of 18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * Lesser General Public License for more details. 20 * Lesser General Public License for more details.
21 * 21 *
22 * You should have received a copy of the GNU Lesser General Public 22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the 23 * License along with this library; if not, write to the
24 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 24 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
25 * Boston, MA 02111-1307, USA. 25 * Boston, MA 02111-1307, USA.
26 */ 26 */
27 27
28 #ifdef HAVE_CONFIG_H 28 #ifdef HAVE_CONFIG_H
29 #include "config.h" 29 #include <config.h>
30 #endif 30 #endif
31 31
32 #include <assert.h> 32 #include <assert.h>
33 #include "xdgmimemagic.h" 33 #include "xdgmimemagic.h"
34 #include "xdgmimeint.h" 34 #include "xdgmimeint.h"
35 #include <stdio.h> 35 #include <stdio.h>
36 #include <stdlib.h> 36 #include <stdlib.h>
37 #include <string.h> 37 #include <string.h>
38 #include <ctype.h> 38 #include <ctype.h>
39 #include <errno.h> 39 #include <errno.h>
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 return; 804 return;
805 805
806 if (fread (header, 1, 12, magic_file) == 12) 806 if (fread (header, 1, 12, magic_file) == 12)
807 { 807 {
808 if (memcmp ("MIME-Magic\0\n", header, 12) == 0) 808 if (memcmp ("MIME-Magic\0\n", header, 12) == 0)
809 _xdg_mime_magic_read_magic_file (mime_magic, magic_file); 809 _xdg_mime_magic_read_magic_file (mime_magic, magic_file);
810 } 810 }
811 811
812 fclose (magic_file); 812 fclose (magic_file);
813 } 813 }
OLDNEW
« no previous file with comments | « base/third_party/xdg_mime/xdgmimeint.c ('k') | base/third_party/xdg_mime/xdgmimeparent.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698