~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/internal/my_symlink2.cc

  • Committer: Brian Aker
  • Date: 2010-07-28 23:07:42 UTC
  • mto: This revision was merged to the branch mainline in revision 1671.
  • Revision ID: brian@gaz-20100728230742-idji8pjd3trphd1a
Fix up a few additional cases around case insensitive usage for
unordered_map. This also places the code in util/string.h behind an
additional namespace of "util"

Show diffs side-by-side

added added

removed removed

Lines of Context:
11
11
 
12
12
   You should have received a copy of the GNU General Public License
13
13
   along with this program; if not, write to the Free Software
14
 
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA */
 
14
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
15
15
 
16
16
/*
17
17
  Advanced symlink handling.
20
20
  rename files and symlinks like they would be one unit.
21
21
*/
22
22
 
23
 
#include <config.h>
 
23
#include "config.h"
24
24
 
25
 
#include <drizzled/internal/my_sys.h>
26
 
#include <drizzled/error.h>
27
 
#include <drizzled/internal/m_string.h>
 
25
#include "drizzled/internal/my_sys.h"
 
26
#include "drizzled/error.h"
 
27
#include "drizzled/internal/m_string.h"
28
28
 
29
29
namespace drizzled
30
30
{
64
64
  {
65
65
    if (!access(filename,F_OK))
66
66
    {
67
 
      errno= EEXIST;
 
67
      errno= errno= EEXIST;
68
68
      my_error(EE_CANTCREATEFILE, MYF(0), filename, EEXIST);
69
69
      return(-1);
70
70
    }
71
71
    if (create_link && !access(linkname,F_OK))
72
72
    {
73
 
      errno= EEXIST;
 
73
      errno= errno= EEXIST;
74
74
      my_error(EE_CANTCREATEFILE, MYF(0), linkname, EEXIST);
75
75
      return(-1);
76
76
    }