All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <20200512174706.GA298379@mwanda>

diff --git a/a/1.txt b/N1/1.txt
index ccc38e5..42fb280 100644
--- a/a/1.txt
+++ b/N1/1.txt
@@ -14,7 +14,7 @@ fails and returns an error pointer.
 
 And the second thread is here:
 
-	if (*tfm = NULL) {  <--- SECOND THREAD HERE!
+	if (*tfm == NULL) {  <--- SECOND THREAD HERE!
 		mutex_lock(&mutex);
 		if (*tfm)
 			goto out;
@@ -53,12 +53,12 @@ index 35682852ddea9..c9f7206591b30 100644
 +	struct crypto_shash **tfm, *tmp_tfm;
  	struct shash_desc *desc;
  
- 	if (type = EVM_XATTR_HMAC) {
+ 	if (type == EVM_XATTR_HMAC) {
 @@ -91,31 +91,31 @@ static struct shash_desc *init_desc(char type, uint8_t hash_algo)
  		algo = hash_algo_name[hash_algo];
  	}
  
--	if (*tfm = NULL) {
+-	if (*tfm == NULL) {
 -		mutex_lock(&mutex);
 -		if (*tfm)
 -			goto out;
@@ -80,14 +80,14 @@ index 35682852ddea9..c9f7206591b30 100644
 +		mutex_unlock(&mutex);
 +		return ERR_CAST(tmp_tfm);
 +	}
-+	if (type = EVM_XATTR_HMAC) {
++	if (type == EVM_XATTR_HMAC) {
 +		rc = crypto_shash_setkey(tmp_tfm, evmkey, evmkey_len);
 +		if (rc) {
 +			crypto_free_shash(tmp_tfm);
  			mutex_unlock(&mutex);
  			return ERR_PTR(rc);
  		}
--		if (type = EVM_XATTR_HMAC) {
+-		if (type == EVM_XATTR_HMAC) {
 -			rc = crypto_shash_setkey(*tfm, evmkey, evmkey_len);
 -			if (rc) {
 -				crypto_free_shash(*tfm);
diff --git a/a/content_digest b/N1/content_digest
index 973d4aa..333f73e 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -1,7 +1,7 @@
  "ref\0c7743ab21a574eeeac40d783e0b8581c@huawei.com\0"
  "From\0Dan Carpenter <dan.carpenter@oracle.com>\0"
  "Subject\0[PATCH v2] evm: Fix a small race in init_desc()\0"
- "Date\0Tue, 12 May 2020 17:47:06 +0000\0"
+ "Date\0Tue, 12 May 2020 20:47:06 +0300\0"
  "To\0Mimi Zohar <zohar@linux.ibm.com>"
   Roberto Sassu <roberto.sassu@huawei.com>
  " Krzysztof Struczynski <krzysztof.struczynski@huawei.com>\0"
@@ -29,7 +29,7 @@
  "\n"
  "And the second thread is here:\n"
  "\n"
- "\tif (*tfm = NULL) {  <--- SECOND THREAD HERE!\n"
+ "\tif (*tfm == NULL) {  <--- SECOND THREAD HERE!\n"
  "\t\tmutex_lock(&mutex);\n"
  "\t\tif (*tfm)\n"
  "\t\t\tgoto out;\n"
@@ -68,12 +68,12 @@
  "+\tstruct crypto_shash **tfm, *tmp_tfm;\n"
  " \tstruct shash_desc *desc;\n"
  " \n"
- " \tif (type = EVM_XATTR_HMAC) {\n"
+ " \tif (type == EVM_XATTR_HMAC) {\n"
  "@@ -91,31 +91,31 @@ static struct shash_desc *init_desc(char type, uint8_t hash_algo)\n"
  " \t\talgo = hash_algo_name[hash_algo];\n"
  " \t}\n"
  " \n"
- "-\tif (*tfm = NULL) {\n"
+ "-\tif (*tfm == NULL) {\n"
  "-\t\tmutex_lock(&mutex);\n"
  "-\t\tif (*tfm)\n"
  "-\t\t\tgoto out;\n"
@@ -95,14 +95,14 @@
  "+\t\tmutex_unlock(&mutex);\n"
  "+\t\treturn ERR_CAST(tmp_tfm);\n"
  "+\t}\n"
- "+\tif (type = EVM_XATTR_HMAC) {\n"
+ "+\tif (type == EVM_XATTR_HMAC) {\n"
  "+\t\trc = crypto_shash_setkey(tmp_tfm, evmkey, evmkey_len);\n"
  "+\t\tif (rc) {\n"
  "+\t\t\tcrypto_free_shash(tmp_tfm);\n"
  " \t\t\tmutex_unlock(&mutex);\n"
  " \t\t\treturn ERR_PTR(rc);\n"
  " \t\t}\n"
- "-\t\tif (type = EVM_XATTR_HMAC) {\n"
+ "-\t\tif (type == EVM_XATTR_HMAC) {\n"
  "-\t\t\trc = crypto_shash_setkey(*tfm, evmkey, evmkey_len);\n"
  "-\t\t\tif (rc) {\n"
  "-\t\t\t\tcrypto_free_shash(*tfm);\n"
@@ -125,4 +125,4 @@
  "-- \n"
  2.26.2
 
-d81295ced3ccf94892db6b777310d43de822e27eb5c3d02b3c33134124c3a63d
+efcfb227fd5bf55b42cde4dc6504dee557b9df32d130a35cb6a1aba3804f31d7

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.