Electroencephalography (EEG) based emotion recognition studies have been conducted in recent years. Most prior researches are based on subject-dependent models since EEG signals have a large variation between individuals. In this paper, we propose a novel EEG-based emotion recognition approach that addresses the challenging issue of the subject-dependency. To solve the problem, we design a multi-task deep neural network, which consists of two objectives. The first one is to classify subject-independent emotional labels, and the second is to make the model cannot distinguish the subject labels. To achieve the latter purpose, we adversarially learn the proposed model, which has three components: 1) Emotion classification module, 2) Subject classification module, 3) Adversarial module. To make the model confuse the subject labels, we apply the randomization function to the subject classification module for adversarial learning. For the experiment, we evaluate the proposed method to classify EEG emotional labels with a leave-one-subject-out scheme on SEED dataset, which has recorded EEG from 15 participants and contains three emotional labels: Positive, negative, and neutral. We compare the proposed method with a single-task deep neural network and multi-task model that classify emotional labels with subject labels. Our experimental results show that the proposed method achieves better results than the others with an average accuracy of 75.31%. Moreover, the standard deviation of our model was 7.33%, which is the lowest with the compared models.